Our Blog, Filemaker only, Xojo only, Archive (older), Follow us on Twitter, Xing, LinkedIn or Facebook.


Trigger FileMaker Scripts from JavaScript in FileMaker 16


As you may know FileMaker 16 on macOS uses WebKit 2.x, so our old WebView.InstallCallback function broke. We got a workaround using WebView.Create for creating WebKit 1.x web viewers in FileMaker 16 and using older WebKit functions.

Now we have a new way for WebKit 2.x using a JavaScript bridging. With macOS 10.10 (and iOS 8.0) Apple introduced the ability to install custom JavaScript message handlers for WKWebView. We just added them for our plugins to call back from JavaScript to FileMaker scripts.
First you call Webview.AddScriptMessageHandler function to register a name:

MBS( "Webview.AddScriptMessageHandler"; Name )

Next you can use it in Javascript to trigger a script in FileMaker from JavaScript:

window.webkit.messageHandlers.test.postMessage({'filename':'WebView Message Handler.fmp12', 'parameter':'Hello World from JavaScript', 'scriptName':'test'});

And you can evaluate an expression in JavaScript:

window.webkit.messageHandlers.test.postMessage({'evaluate':'MBS( "Msgbox"; "Hello from Evaluate in JavaScript" )'});

As you see, we get for our message handler a new entry in the namespace called window.webkit.messageHandlers.test. This allows us to call postMessage method there and this triggers the plugin code to trigger scripts or do evaluation. The parameter to the postMessage must be a Javascript object with a few properties:
  • fileName: The name of the file with the script.
  • scriptName: The name of the script to trigger.
  • parameter: The parameter to pass to the script.
  • evaluate: The expression to evaluation.
This works nice in first tests and we'd love to see what you can do with this technique. Please try with next prerelease or email us for a copy today.

PS: Works in FileMaker 16 runtimes, too.

Upload email to Sent folder via IMAP


As you know you can send emails via the CURL functions in MBS Plugins for Xojo and FileMaker. To have your mails how up in sent folder, you need to upload them to the IMAP server. The following script does it for FileMaker. Key thing is to pass in URL to IMAP Server with name of Mailbox, e.g. "imap://imap.monkeybreadsoftware.de/INBOX.Sent". Than you set the upload option and provide the data to send. Of course you should use SSL, certificate verification and pass in your credentials. So here the FileMaker script from the sample database:
 

Set Variable [ $curl ; Value: MBS("CURL.New") ] 

# Set URL with name of the mailbox included:

Set Variable [ $result ; Value: MBS("CURL.SetOptionURL"; $curl; CURL Test::URL & "/INBOX.Sent") ] 

# We upload

Set Variable [ $result ; Value: MBS("CURL.SetOptionUpload"; $curl; 1) ] 

Set Variable [ $email ; Value: CURL Test::email ] 

Set Variable [ $email ; Value: MBS("Text.ReplaceNewline"; $email; 3) ] 

Set Variable [ $result ; Value: MBS("CURL.SetInputText"; $curl; $email; "UTF-8") ] 

# your credenticals

Set Variable [ $result ; Value: MBS("CURL.SetOptionPassword"; $curl; CURL Test::Password) ] 

Set Variable [ $result ; Value: MBS("CURL.SetOptionUsername"; $curl; CURL Test::Name) ] 

# Maybe use alternative IMAP port?

// Set Variable [ $r ; Value: MBS("CURL.SetOptionPort"; $curl; 143) ] 

# This turns TLS on and requires connection to be encrypted

Set Variable [ $r ; Value: MBS("CURL.SetOptionUseSSL"; $curl; 3) ] 

# force TLS v1.2

Set Variable [ $r ; Value: MBS("CURL.SetOptionSSLVersion"; $curl; 6) ] 

# This disables certificate verification, so we accept any: 

Set Variable [ $r ; Value: MBS("CURL.SetOptionSSLVerifyHost"; $curl; 0) ] 

Set Variable [ $r ; Value: MBS("CURL.SetOptionSSLVerifyPeer"; $curl; 0) ] 

# Better with certificates if you have some:

// Set Variable [ $r ; Value: MBS( "CURL.SetOptionCAInfo"; $curl; "/Library/FileMaker Server/certificates.pem") ] 

// Set Variable [ $r ; Value: MBS("CURL.SetOptionSSLVerifyHost"; $curl; 2) ] 

// Set Variable [ $r ; Value: MBS("CURL.SetOptionSSLVerifyPeer"; $curl; 1) ] 

Set Variable [ $result ; Value: MBS("CURL.SetOptionVerbose"; $curl; 1) ] 

# do it!

Set Field [ CURL Test::Result ; MBS("CURL.Perform"; $curl) ] 

# Check result:

Set Field [ CURL Test::debug ; MBS("CURL.GetDebugAsText"; $curl) ] 

Set Variable [ $result ; Value: MBS("CURL.Cleanup"; $curl) ] 


Let me know whether this works fine for you. 
 
For Xojo this translate more or less 1:1 to the CURLSMBS class. The properties have the same name and you just pass email via SetInputData method. Just remember to make sure to use ReplaceLineEndings with EndOfLine.Windows.

MBS FileMaker Plugin, version 7.6pr3


New in this prerelease of the 7.6 MBS FileMaker Plugin: Download at monkeybreadsoftware.de/filemaker/files/Prerelease/ or ask for being added to the dropbox shared folder.

Install fonts for PDF generation in FileMaker Cloud


As you may have noted, FileMaker Could comes preinstalled with around 50 font faces. The font you love and use in layouts may not be included in the list. The fonts include in various styles:
  • Baekmuk Batang
  • Utopia
  • URW Gothic L
  • URW Bookman L
  • Century Schoolbook L
  • Dingbats
  • Nimbus Sans L
  • Nimbus Roman No9 L
  • Nimbus Mono L
  • URW Palladio L
  • Standard Symbols L
  • URW Chancery L
  • IPAPGothic
  • Liberation Mono
  • Liberation Sans
  • WenQuanYi Micro Hei Mono
  • WenQuanYi Micro Hei
  • WenQuanYi Zen Hei Mono
  • WenQuanYi Zen Hei Sharp
  • WenQuanYi Zen Hei
If you like, you can install more fonts with those easy steps:
  1. Get login for your FileMaker Cloud Server via SSH.
  2. Create a new folder in /usr/share/fonts folder for your fonts.
    e.g. sudo mkdir --mode=777 /usr/share/fonts/myfonts
  3. Copy fonts in your new folder.
  4. Run "fc-cache -f -v" command to update cache.
  5. You can verify with "fc-list" command whether fonts were found.
  6. Reboot machine or at least restart the WebDirect engine.
Now you can create PDFs with any font you like. Let me know if it works for you.

You can use MBS( "DynaPDF.AddFontSearchPath"; $PDF; "/usr/share/fonts"; 1 ) with our DynaPDF functions to use the fonts on the FileMaker Cloud.

MBS FileMaker Plugin, version 7.6pr2


New in this prerelease of the 7.6 MBS FileMaker Plugin: Download at monkeybreadsoftware.de/filemaker/files/Prerelease/ or ask for being added to the dropbox shared folder.

LDAP with JSON


For the next plugin prerelease, we introduce three JSON functions for use with our LDAP functions.

So you can use query and get the result as JSON with the new LDAP.JSON function. See this little example which connects and makes a query and finally shows the JSON in a dialog:

# Connect

Variable setzen [ $r ; Wert: MBS("LDAP.Connect"; "ldap.forumsys.com"; 0; 389) ] 

Wenn [ MBS("IsError") ] 

Eigenes Dialogfeld anzeigen [ "LDAP error" ; "Failed to connect." & ¶ & $r ] 

Sonst

Variable setzen [ $ldap ; Wert: $r ] 

# Login

Variable setzen [ $r ; Wert: MBS("LDAP.Bind"; $ldap; "uid=tesla,dc=example,dc=com"; "password"; "simple") ] 

Wenn [ MBS("IsError") ] 

Eigenes Dialogfeld anzeigen [ "LDAP error" ; "Failed to authenticate." & ¶ & $r ] 

Sonst

# Search

Variable setzen [ $r ; Wert: MBS("LDAP.Search"; $ldap; "dc=example,dc=com"; "subtree"; "(givenName=*)"; ""; 0; 20; 999) ] 

# Check results

Eigenes Dialogfeld anzeigen [ "JSON" ; MBS("LDAP.JSON"; $ldap) ] 

Ende (wenn)

# Cleanup

Variable setzen [ $r ; Wert: MBS("LDAP.Release"; $ldap) ] 

Ende (wenn)

 
The answer in JSON looks like this:
 

[{

"dn": "uid=test,dc=example,dc=com",

"attributes": [{

"name": "objectClass",

"values": ["posixAccount", "top", "inetOrgPerson"]

}, {

"name": "gidNumber",

"values": ["0"]

}, {

"name": "givenName",

"values": ["Test"]

}, {

"name": "sn",

"values": ["Test"]

}, {

"name": "displayName",

"values": ["Test"]

}, {

"name": "uid",

"values": ["test"]

}, {

"name": "initials",

"values": ["TS"]

}, {

"name": "homeDirectory",

"values": ["home"]

}, {

"name": "cn",

"values": ["Test"]

}, {

"name": "uidNumber",

"values": ["24601"]

}, {

"name": "o",

"values": ["Company"]

}]

}]
 
So we have an array of entries fill with an object for each entry. Each entry has attributes and there each value can have several values. 
 
For add, modify or delete, you can now use the LDAP.AddJSON and LDAP.ModifyJSON functions to pass in JSON formatted changes.
The structure looks like this:

[{
    "operation": "Add",
    "type": "xxx",
    "values": ["Hello", "World"]
},
{
    "operation": "Replace",
    "type": "yyy",
    "value": "Other"
},
{
    "operation": "Delete",
    "type": "zzz"
}]

Please try in next prelease.


FileMaker Cloud Tipps & Tricks


First, you may know we used to simply restart the FileMaker Cloud instance when we installed a new plugin. That is due to the fact that if old and new plugin have the same file name and the OS can’t distinguish them. When FileMaker tries to load a new one, it still gets the handle for the old plugin copy. I suggested to FileMaker Inc. to make a hard link to load it with a random postfix in file name.

But we found a workaround. You can simply rename the plugin each time before adding it to the container to upload. So if first plugin is MBS1.fmx and you install MBS2.fmx via Install Plugin Script Step, you get the new one loaded and the old file is deleted. That’s great way to solve this. For the next plugins, we simply include the build number in the linux file name, e.g. MBS.3100.fmx to help you install it easily.

Second, whenever a plugin crashes the FileMaker Server scripting process, you see error 812 on the client. That can be irritating, but it simply means the client didn’t get an answer due to the lost connection.

Third, you may want to see debug messages from the plugin. Especially if we want to debug an issue. As none of the log files so far contain our debug messages, we change the plugin for next prerelease to redirect them itself. Within the /FileMakerData/Logs folder we create two new files ServerScriptingPluginsStdOut.log and ServerScriptingPluginsStdErr.log to log messages from stdout and stderr. Trace messages and debug messages end up in stderr. Regular outputs of messages may be in the stdout file.

I now usually connect two Terminal windows via SSH and run the commands to output the files live:

tail -f ServerScriptingPluginsStdOut.log
tail -f ServerScriptingPluginsStdErr.log

So in both windows I can watch live what is going on. To exit tail, you can press Control-C.

Forth, the FileMaker Cloud linux is secure. This includes that you can’t simply list all environment variables. EnvironmentVariables.Names returns an empty list. But you can still query some variables:
MBS( "EnvironmentVariables.Value"; "LANG" ) returns "en_US.UTF-8"

The MBS Plugin performs well on the FileMaker Cloud, although that's currently only 5% of the servers out there as far as we know about. Popular functions used on the FileMaker Cloud include our CURL functions, SQL functions within FileMaker and JSON functions.

Three weeks till year's end


The year 2017 will end in less than three weeks. Do you need some more licenses?
  • You can order licenses for 2018 or later and have invoice, delivery and payment done in 2017.
    This way you secure the current pricing and the possibility to keep upgradeability for older licenses.
  • And of course you can order updates for several years in advance for all your MBS products.
  • DynaPDF licenses are on sale for December 2017 with 25% automatically.
  • As all our Xojo and DynaPDF plugin licenses are per developer, you should check if you got a new developer in your team this year and adjust licenses to match team size.
  • If you need a Xojo license (new or update), we can always check whether a bundle with Xojo offers an advantage for you. Or we can point you to the next sale or a coupon code for the Xojo Store.
  • For FileMaker please check if you have enough license for the number of seats or servers you have in use.
    If you upgrade to unlimited seats or servers, the plugin won't need to check the usage.
Especially if you run on a budget and you want to spend some money in the old year, you can buy updates for several years in advance.
If you need help to decide what Xojo, FileMaker or plugin license you need, we may be able to assist you.

FileMaker Magazin - MBS Artikel


For our German speaking users:

Wir haben die Artikel zum MBS Plugin aus dem FileMaker Magazin gesammelt hier online gestellt:
FileMaker Magazin Artikel:

Wir empfehlen allen FileMaker Anwender ein Abo vom Magazin und den Kauf der alten Ausgaben. Das FileMaker Magazin ist eine excellente Quelle von Informationen, Anleitungen und Profitips.


MBS FileMaker Plugin, version 7.6pr1


New in this prerelease of the 7.6 MBS FileMaker Plugin: Download at monkeybreadsoftware.de/filemaker/files/Prerelease/ or ask for being added to the dropbox shared folder.

List of DynaPDF error codes


For your convenience, here a list of all error codes with messages for lookup.

DynaPDF Error List

Don't forget the DynaPDF Christmas Sale. A great chance to upgrade and add maintenance at lower prices.

FileMaker Cloud, best with BYOL


Be aware of a little limitation when using FileMaker Cloud with annual subscriptions for the FileMaker Server software with AWS:

If you purchased an annual licnese via the Amazon Marketplace, do not change the instance size after installation. Doing so will switch your instance to become hourly billed.


So if you ever plan to up/downscale without hassle on the FileMaker Cloud servers, you better go and buy the license from FileMaker directly (or a your favorite reseller).

With that license, you can easily switch from t2.medium on development (2 cores, 4 GB RAM) to t2.large (2 cores, 8 RAM) for a beta test and up to t2.2xlarge (8 cores and 32 GB RAM) for deployment on busy days. It would be pity if your next AWS bill for FIleMaker Cloud would be $700 for hourly billing, because you just changed instance type.

And you can use one license over the year for several servers independently. e.g. buy a FileMaker Server for a project in February, terminate the server in April and later in August start a new one for another project with the existing license.

For details, please check answer 25984.

Following the license rules


We are software developers and make a living from selling our software. Ourselves we pay for licenses to enable others to make a living. This includes paying royalties for libraries used in our plugins which enable the continued development of those libraries. And we expect our clients to pay their license fees and indeed the majority does it correctly and pays their bills.

Technically we don’t enforce it directly. Xojo itself has a server based activation, FileMaker Pro doesn’t, but the Server talks back to FileMaker Inc.. Personally we don’t like to use an activation for the plugins, so we only check license keys locally. We also do some statistics on the usage of the plugins, so we know what versions are in use on which operation systems. And we can see which license keys are in use.

The licensing terms for Xojo and FileMaker are quite clear. You can have a trial for FileMaker Pro and for Xojo simply use the software without a license. Those are limited in a couple of ways. But when you get productive, you should really get a license key. You need one license per developer and you do not share license between developrs. For Xojo you need to have a Pro key to use version control software, so you buy the Pro licenses when you want take part in a bigger development project. For FileMaker you should have a license for Pro Advanced when you develop and of course you pay it.

For using plugins we expect that you match the licenses for plugins with those for Xojo and FileMaker. So if you have two Xojo licenses for two developers and both developers work on the projects using the plugins, we expect you to buy two licenses. We want bigger companies to contribute more for the tools than a small one person company. For FileMaker you pay for each server a license to FileMaker Inc. and we expect that you also pay for each server using MBS Plugin the license fee to us. That may result in paying for every developer including trainees and managers. We do know that some things may be temporary and for that reason like to issue trial keys to use our plugins without paying for a limited time.

Luckily the statistics show that nearly everybody obeys the licensing terms and that makes me happy. We do have Xojo plugins in use for development on at least a thousand computers. We don’t know about deployment as we don’t want to track that! Still MBS Xojo Plugins is used in thousands of applications with properly hundred thousands installations. I know some Xojo applications using my plugins which sold over 10000 times. Our FileMaker plugin is used on tens of thousands computers and that makes us happy. We got some success there over the years.

On the other side the statistics reveal some really bad guys. We learnt that there are license keys used, which we never created. Someone clearly hacked the plugins. And some users really use the plugin on much more computers than intended. Like the company who runs 26 servers with just one server license for our FileMaker plugin. Or a company with eight Xojo developers and just one license key. Same with a FileMaker solution with a 5 seats key, which was in use on 21 computers on a single day last month. And those calculations include a filter which removes the occasional use of a key for a day or two on another computer.

Today I double checked this and contacted a few clients which exceed the license terms a lot. Not the job I like to do.

Booked for Montreal


For the upcoming Québec FileMaker Developers Conference (QFDC) next year in Montreal, I am happy to be signed up a sponsor and I booked my flight already. Due to flights being much cheaper going to Toronto, I will come to visit that nice town and maybe organize a local developer meeting there.

Montreal at night

The conference will probably be announced soon, but it may be good to keep mid March free for now.

Birthday of our video page


Ten years ago we started created tutorial videos and today our video page has birthday. Enjoy a video and learn about our plugins.

Over the years we collected more than 80 videos. We hope you enjoy them!

Watch Xojo Videos - FileMaker Videos

Youtube channels:

We know we could make more videos. So what wishes do you have?
Please email us or post a comment here.

DynaPDF Christmas Sale


We just got notice from DynaForms about their Christmas Sale for this year:

Christmas Special: 25% Off on anything!

As a thank you for the good collaboration and your trust, you get 25% Christmas Discount on anything til the end of the year!

I wish you and your family Merry Christmas and a successful new year.

With kind regards

DynaForms GmbH

The MBS online shop is updated and we reduced all our DynaPDF prices by 25%. So if you need a new license or updates for up to five years, please order. If you have questions, please do not hesitate to contact us.
Order for Xojo - Order for FileMaker

PDFKit on iOS for MBS FileMaker Plugin


As Apple added support for PDFKit to iOS with version 11, we thought we may use it for FileMaker, too.

And indeed, our PDFKit functions can work on iOS, too. Printing is not available and Quartz Filters are macOS only.
But other functions like rendering a PDF page or merging several PDFs into one works well.

So you can now do PDF append operation on iOS with our plugin, e.g. using PDFKit.AppendPages function. The following scripts merges two PDFs and stores the resulting PDF in a new container:

Set Variable [ $pdf ; Value: MBS("PDFKit.OpenContainer"; MyTable::InputPDF) ]
Set Variable [ $r ; Value: MBS( "PDFKit.AppendPages"; $pdf; MyTable::OtherPDF ) ]
Set Field [ MyTable::OutputPDF ; MBS( "PDFKit.GetPDFDocument"; $PDF) ]
Set Variable [ $r ; Value: MBS( "PDFKit.Release"; $pdf) ]

You can of course decide whether you like to use PDFKit or you need more and use our DynaPDF functions. With DynaPDF we have a cross platform library which provides constant behavior on all platforms. PDFKit is great for the average user, but if you need PDF/A, separation/process colors or optimization, you need more. See DynaPDF features.

The new features can be tested with the upcoming beta version in a few days. If you like to try them earlier, please do not hesitate to contact us.

Amazon S3 Upload with Mime Type and Permissions


As you may know we have functions to do authentication for Amazon WebServices in our plugins for Xojo and FileMaker. This functions can be used with various webservices from Amazon, but today we use S3 as example and upload an image from a container.

You can pass additional headers with the upload to specify permissions and content type. For example you can grant permissions to everyone with acl public-read. When you pass the content type, you get back that same content type when downloading. Here an example upload:

# Change to your own credentials, region, bucket name, file name...

Set Variable [ $AWSAccessKeyId ; Value: "AKIAK21ZENQFJ3EFLKJA" ] 

Set Variable [ $AWSSecretAccessKey ; Value: "4TMeKFtn62xDfAP6F1cENwHehRqo75kQKoT/BAKE" ] 

Set Variable [ $Region ; Value: "eu-central-1" ] 

Set Variable [ $Bucketname ; Value: "mbstest" ] 

Set Variable [ $Filename ; Value: "test.jpg" ] 

Set Variable [ $Headers ; Value: "Content-Type: image/jpeg¶x-amz-acl: public-read" ] 

Set Variable [ $Service ; Value: "s3" ] 

Set Variable [ $Verb ; Value: "PUT" ] 

# Keep those empty for default

Set Variable [ $Domain ; Value: "" ] 

Set Variable [ $HashedPayload ; Value: "" ] 

# Build a path

Set Variable [ $Path ; Value: "/" & $BucketName & "/" & $Filename ] 

# Run transfer

Set Variable [ $curl ; Value: MBS("CURL.New") ] 

Set Variable [ $result ; Value: MBS("CURL.SetInputFile"; $curl; CURL Test::Image) ] 

Set Variable [ $result ; Value: MBS("CURL.SetupAWS"; $curl; $AWSAccessKeyId; $AWSSecretAccessKey; $Region; $Service; $Path; $Domain; $Verb; ""; $Headers) ] 

Set Field [ CURL Test::Result ; MBS("CURL.Perform"; $curl) ] 

Set Field [ CURL Test::debug ; MBS("CURL.GetDebugAsText"; $curl) ] 

Set Variable [ $result ; Value: MBS("CURL.Cleanup"; $curl) ] 

Same upload works in Xojo with our MBS Xojo CURL Plugin

Please do not hesitate to contact us with questions.


Print WebViewer on macOS in FileMaker


Today an user send us a script which does printing of a webviewer with some report (in HTML) to a PDF file. The code works pretty well and prints automatically dozens of reports to PDF files:

# Check plugin version installed to use right key

Set Variable [ $_MBS_Version ; Value: MBS("Version") ] 

Set Variable [ $_MBS_Version_asNumber ; Value: Substitute ( GetAsNumber ( $_MBS_Version ) ; "?" ; 0 ) ] 

If [ MBS("isRegistered") ≠ 1 ] 

If [ $_MBS_Version_asNumber >= 7 ] 

# Version 7 with newer code

Set Variable [ $_MBS ; Value: MBS("Register"; "ABC"; "Complete"; "5 seats"; 201803; "###") ] 

Else

# Version 6 with older code

Set Variable [ $_MBS ; Value: MBS("Register"; "ABC"; "Complete"; "5 seats"; 201702; "xyz") ] 

End If

End If

# Destination file path, could be a parameter to the script.

Set Variable [ $_Path_Destination_Complete ; Value: "/tmp/test.pdf" ] 

# Page to load and print

Set Variable [ $URL ; Value: "https://www.mbsplugins.de" ] 

# Check plugin version needed for FileMaker 16

If [ GetAsNumber ( Get(ApplicationVersion) ) >= 16 and $_MBS_Version_asNumber < 7,4 ] 

Show Custom Dialog [ "Process: Error" ; "Filemaker 16 or greater requires MBS Plugin version 7.4 or higher." ] 

Halt Script

End If

# Set print parameters

Set Variable [ $_MBS ; Value: MBS( "WebView.SetPrintParameter"; "topMargin"; 0 ) ] 

Set Variable [ $_MBS ; Value: MBS( "WebView.SetPrintParameter"; "bottomMargin"; 0 ) ] 

Set Variable [ $_MBS ; Value: MBS( "WebView.SetPrintParameter"; "leftMargin"; 0 ) ] 

Set Variable [ $_MBS ; Value: MBS( "WebView.SetPrintParameter"; "RightMargin"; 30 ) ] 

If [ $_MBS_Version_asNumber >= 7,4 ] 

Set Variable [ $x ; Value: 0 ] 

Set Variable [ $y ; Value: 100 ] 

Set Variable [ $w ; Value: 970 ] 

Set Variable [ $h ; Value: 440 ] 

# Create a webviewer via plugin to use older WebKit which can print

Set Variable [ $$web ; Value: MBS("Webview.Create"; 0; $x; $y; $w; $h) ] 

Set Variable [ $error ; Value: MBS("IsError") ] 

If [ $error = 0 ] 

# Load URL

Set Variable [ $_MBS ; Value: MBS( "WebView.LoadURL"; $$web; $URL) ] 

# Wait for loading

Set Variable [ $_WebViewer_isLoading ; Value: True ] 

Loop

Pause/Resume Script [ Duration (seconds): ,2 ] 

Exit Loop If [ MBS( "WebView.IsLoading"; $_theWebViewerID ) ≠ 1 ] 

End Loop

# print webviewer

Set Variable [ $_MBS ; Value: MBS( "WebView.PrintToFile"; $$web ; $_Path_Destination_Complete ) ] 

Set Variable [ $error ; Value: MBS("IsError") ] 

# close webviewer

Set Variable [ $r ; Value: MBS( "WebView.Close"; $$web) ] 

End If

Else

# Print WebViewer Contents to tmp folder

Set Variable [ $_theWebViewerID ; Value: "web" ] 

# print webviewer

Set Variable [ $_MBS ; Value: MBS( "WebView.PrintToFile"; $_theWebViewerID ; $_Path_Destination_Complete ) ] 

Set Variable [ $error ; Value: MBS("IsError") ] 

End If

If [ $error ] 

Show Custom Dialog [ "Process: Error" ; List ( "Failed to save file [" & $_Path_Destination_Complete & "]" ; MBS("Text.RemovePrefix"; $_MBS… ] 

Halt Script

End If

 

As you see they use either an existing WebViewer on the layout or use the plugin provided one if possible. As WebKit 2.x does not print, but FileMaker 16 only uses the new version, we have to make a webviewer ourselves via plugin functions using older WebKit 1.x.


MBS FileMaker Plugin 7.5 - More than 5000 Functions In One Plugin


Nickenich, Germany - (November 28th, 2017) -- MonkeyBread Software today is pleased to announce MBS FileMaker Plugin 7.5 for macOS, iOS, Linux and Windows, the latest update to their product that is easily the most powerful plugin currently available for FileMaker Pro. As the leading database management solution for Windows, macOS, iOS and the web, the FileMaker Pro Integrated Development Environment supports a plugin architecture that can easily extend the feature set of the application. MBS FileMaker Plugin 7.5 has been updated and now includes over 5000 different functions, and the versatile plugin has gained more new functions:

Our new shell functions allow you to run other applications in the background on macOS, Windows and Linux. You can pass command line parameters, read output messages and send input text to the application. Your script can either wait for the results or you just let the application run in background and get a script triggered when the job is done. You can use various command line tools in FileMaker this way like scripts written in python or unpacking a tar archive.

The Regular expression functions can now do replace and replace all operations. You can search for a pattern, capture various texts and use the captured findings in the output text. Our new quote function helps you to escape texts for use in regular expressions.

We added the possibility to create trial license keys. This is a mode between demo mode (no license) and licensed mode. Trials are time limited and only for testing the plugin without demo dialogs. When trial ends, the plugins fall back to demo mode including any deployed solution.

Our DynaPDF functions can now replace images and you can provide replacement ICC profiles via container fields.

The syntax coloring functions got updated with a couple of bug fixes. Especially the functions like script search and script colors should now work on macOS High Sierra. We got new commands to hide/show scripts and scripts steps in the script workspace window. You can search in a script by a script and hide/show layout IDs.

For editing word files, we added functions to append to another word document. For form fields in your document, you can now list those fields, query values and set them.

When using the FileMaker iOS SDK, you can now fully use the JavaScript functions without WebViewer. CoreLocation and CLGeocoder functions are now available to query device location.

For Linux version running on FileMaker cloud we fixed an importing linking bug, so we now always use our own libraries and not the ones provided by FileMaker itself. So SFTP via CURL now works again. We can now also store registration key in local file on cloud server, so registration is not needed in scripts.

The OCR engine can now run in number only mode and writing OCRed text to PDF can now reduce font size to match original text width.

We added a help menu entry for MBS Plugin, JSON handling for 64-bit integers, list dialog sorting, better tracing, socket functions for multicast and change dock image for a window.

Finally we updated CURL library to version 7.56.0, DynaPDF to 4.0.14.39, LCMS to 2.9 and SQLite to 3.20.1.

See release notes for a complete list of changes.

Older blog entries:

2017-11-28 MBS FileMaker Plugin 7.5 - Über 5000 Funktionen in einem Plugin
2017-11-23 MBS FileMaker Plugin, version 7.5pr9
2017-11-23 DynaPDF Funktionen im MBS FileMaker Plugin
2017-11-23 FileMaker Experience Event in der Schweiz
2017-11-22 Xojo Web Apps on FileMaker Cloud Server
2017-11-18 MBS FileMaker Plugin, version 7.5pr8
2017-11-17 Transparent Screensaver for macOS
2017-11-16 Convert to MP3 with new Shell commands and ffmpeg
2017-11-15 MBS Workshop in der Schweiz
2017-11-15 MBS Workshop @ Denkform
2017-11-13 Parsing VCard file
2017-11-13 MBS FileMaker Plugin, version 7.5pr7
2017-11-12 Upcoming changes for 2018 in MBS Plugins
2017-11-11 5000 Functions in MBS Plugin
2017-11-08 Prefetching records from databases
2017-11-07 FileMaker Experience Event in der Schweiz
2017-11-06 MBS FileMaker Plugin, version 7.5pr6
2017-11-05 SyntaxColoring in FileMaker for macOS High Sierra coming
2017-11-04 Trial license keys
2017-11-03 Import Calendar Items into FileMaker

Archives

Dec 2017
Sep 2017
Aug 2017
Jul 2017
Jun 2017
May 2017
Apr 2017
Mar 2017
Feb 2017
Jan 2017
Dec 2016
Nov 2016
Oct 2016
Sep 2016
Aug 2016
Jul 2016
Jun 2016
May 2016
Apr 2016
Mar 2016
Feb 2016
Jan 2016
Dec 2015
Nov 2015
Oct 2015
Sep 2015
Aug 2015
Jul 2015
Jun 2015
May 2015
Apr 2015
Mar 2015
Feb 2015
Jan 2015
Dec 2014
Nov 2014
Oct 2014
Sep 2014
Aug 2014
Jul 2014
Jun 2014
May 2014
Apr 2014
Mar 2014
Feb 2014
Jan 2014
Dec 2013
Nov 2013
Oct 2013
Sep 2013
Aug 2013
Jul 2013
Jun 2013
May 2013
Apr 2013
Mar 2013
Feb 2013
Jan 2013
Dec 2012
Nov 2012
Oct 2012
Sep 2012
Aug 2012
Jul 2012
Jun 2012
May 2012
Apr 2012
Mar 2012
Feb 2012
Jan 2012
Dec 2011
Nov 2011
Oct 2011
Sep 2011
Aug 2011
Jul 2011
Jun 2011
May 2011
Apr 2011
Mar 2011
Feb 2011
Jan 2011
Dec 2010
Nov 2010
Oct 2010
Sep 2010
Aug 2010
Jul 2010
Jun 2010
May 2010
Apr 2010
Mar 2010
Feb 2010
Jan 2010
Dec 2009
Nov 2009
Oct 2009
Sep 2009
Aug 2009
Jul 2009
Apr 2009
Mar 2009
Feb 2009
Dec 2008
Nov 2008
Oct 2008
Aug 2008
May 2008
Apr 2008
Mar 2008
Feb 2008
XML: RSS Feed XML: Atom Feed