Drawing commands for MBS Filemaker Plugin

Friday 30 November 2012 at 3:54 pm
Soon coming in the MBS Filemaker plugin:

Drawing commands to modify pictures with GraphicsMagick by drawing rectangles, round rectangles, lines, circles, ellipses and arcs.

Introducing DynaPDF to MBS Filemaker Plugin

Tuesday 27 November 2012 at 2:24 pm
With our latest MBS Filemaker Plugin prerelease we added support for using DynaPDF library in Filemaker. Using newest plugins you can enjoy our new DynaPDF functions. We start with just a few high level functions for the most requested functions:So we have functions to open a PDF for import and import all pages or just selected ones. Also you can read/write document informations like title or subject. You can query page size and page count. With the render page function you can get a picture from a page. Good for creating a thumbnail. And finally you can save a PDF you created. (more)

Storing Registration for MBS Filemaker Plugin

Tuesday 27 November 2012 at 12:29 pm
We plan to do trainings on our MBS FIlemaker Plugin. And for that we had a nice idea. We could store the license key for the training Mac right in the Filemaker preferences. So before the training, we open a little Filemaker database from an USB stick, run a script and apply the registration key. Than whenever someone uses the plugin on that computer, it is automatically registered.
This feature is also good for my presentations in the future where no more warning dialogs for missing licenses will show up.

To store registration you can use a script step like this:

$r = MBS( "StoreRegistration"; Register::LicenseeName; Register::Component; Register::LicenseType; Register::ExpireMonth; Register::SerialNumber )

As registration details are stored in Filemaker preferences, you need to apply this for every Filemaker version you use. This should also work on a server.

MBS Filemaker Plugin, version 3.0pr9

Monday 26 November 2012 at 11:02 pm
New in this prerelease of the 3.0 plugins:
  • Added DynaPDF functions for Mac/Win PDF functions.
  • Added RichText functions for Mac.
  • Added ClearRegistration, IsRegistered and StoreRegistration for preloading registration on Macs used for training.
  • Changed Syntax Coloring to also see functions if between function and braket is a space.
Download at monkeybreadsoftware.de/filemaker/files/Prerelease/.

A nice forum article in German Filemaker Forum

Thursday 22 November 2012 at 12:06 pm
Thanks to Holger Herbst for sharing his experience with our MBS Plugin on the Filemaker Magazin Forum.

See article here: filemaker-magazin.de/forum/beitrag/124809

CURL Tutorial for Filemaker with MBS Plugin

Sunday 18 November 2012 at 4:08 pm
Today we want to show you how to use our CURL functions in the MBS Filemaker Plugin to do some simple tasks. First we download a picture file and than we upload a file with ftp. (more)

MBS Filemaker Plugin, version 3.0pr8

Wednesday 14 November 2012 at 7:33 pm
New in this prerelease of the 3.0 plugins:
  • Added Printer.SetDefaultPrinter, Printer.PrinterName, Printer.PrinterCount and Printer.GetDefaultPrinter.
  • Added String.EncodeToBytes, String.EncodeHexToBase64, String.EncodeBytesToBase64, String.DecodeHexFromBase64, String.DecodeFromBytes and String.DecodeBytesFromBase64.
  • Added WebView.SetEditable, WebView.LoadHTML and WebView.GetEditable.
  • Added String.FindBetween function.
  • Fixed problem with CURL and SFTP transfers (SSH).
  • Improved trace output on Windows.
  • On Filemaker Server we now write to DebugView/Console.app the message that the plugin has been loaded. This makes it easier to verify things are working.
Download at monkeybreadsoftware.de/filemaker/files/Prerelease/.

Filemaker Magazin 5/2012

Monday 12 November 2012 at 3:32 pm
The magazine just arrived. Check it out and read about the Filemaker conference, how I got the plugin award and how to you optimize your Filemaker solutions for retina displays.

Also I have an article about our Runtime Shrinker application.

(of course only if you understand German)

More details on the Filemaker Magazin website.

Tracing MBS Filemaker Plugin

Saturday 10 November 2012 at 2:26 pm
Sometimes you run a script and call 20 MBS plugin functions. But something goes wrong in-between and you'd like to know what function returns an error or gets a bad parameter. Maybe you have a typing error in the function name, a wrong parameter or some function returns an error?

In our plugin we have a special command called Trace. This command lets the plugin output messages for all calls to plugin functions to either a log file or the standard debug console. A file is useful for people developing or if you want your solution to write a log file for your user to send you.

For seeing live trace logs, we normally recommend to simply call MBS("Trace") with no parameters and run Console.app on Mac OS X and DebugView on Windows. The Debugview tool can be downloaded for free from Microsoft. In order to see messages from Filemaker Server, you need to run it as Administrator.

Like when using our Rename Container example database with tracing and you run the RenameIt script, you see output like this:
Nov 10 13:27:34 cs FileMaker Pro[8239]:MBS Plugin called with 3 parameters.
Nov 10 13:27:34 cs FileMaker Pro[8239]:Parameter 0: "Container.Rename"
Nov 10 13:27:34 cs FileMaker Pro[8239]:Parameter 1: Binary Data with 4 streams, 27304 Bytes in total: FNAM "filemac:/SnowLeopard/Users/cs/Desktop/logo.jpg", FORK "........", JPEG "......JFIF.....H.H......Photoshop 3.0.8BIM .......x.(...H.H.......R.......[ ..(.................4...2", SIZE 350 x 350
Nov 10 13:27:34 cs FileMaker Pro[8239]:Parameter 2: "test.jpg"
Nov 10 13:27:34 cs FileMaker Pro[8239]:ErrorCode 0 (no error), Result: Binary Data with 4 streams, 27228 Bytes in total: FNAM "file:test.jpg", FORK "........", JPEG "......JFIF.....H.H......Photoshop 3.0.8BIM .......x.(...H.H.......R.......[ ..(.................4...2", SIZE 350 x 350
Nov 10 13:27:34 cs FileMaker Pro[8239]:MBS Plugin called with 2 parameters.
Nov 10 13:27:34 cs FileMaker Pro[8239]:Parameter 0: "Container.getName"
Nov 10 13:27:34 cs FileMaker Pro[8239]:Parameter 1: Binary Data with 4 streams, 27304 Bytes in total: FNAM "filemac:/SnowLeopard/Users/cs/Desktop/logo.jpg", FORK "........", JPEG "......JFIF.....H.H......Photoshop 3.0.8BIM .......x.(...H.H.......R.......[ ..(.................4...2", SIZE 350 x 350
Nov 10 13:27:34 cs FileMaker Pro[8239]:ErrorCode 0 (no error), Result: "filemac:/SnowLeopard/Users/cs/Desktop/logo.jpg"
Nov 10 13:27:34 cs FileMaker Pro[8239]:MBS Plugin called with 2 parameters.
Nov 10 13:27:34 cs FileMaker Pro[8239]:Parameter 0: "Container.getName"
Nov 10 13:27:34 cs FileMaker Pro[8239]:Parameter 1: Binary Data with 4 streams, 27228 Bytes in total: FNAM "file:test.jpg", FORK "........", JPEG "......JFIF.....H.H......Photoshop 3.0.8BIM .......x.(...H.H.......R.......[ ..(.................4...2", SIZE 350 x 350
Nov 10 13:27:34 cs FileMaker Pro[8239]:ErrorCode 0 (no error), Result: "file:test.jpg"

The first thing you see is that we have three MBS plugin calls there, but the script has only one call. Weird? Actually no as the database defines two field with calculations, so the plugin is called there, too. Now the plugin informs you about the calls and the number of parameters. It writes those parameters to the log. For text you see the text in quotes. For container values, you see Binary Data being listed with very detailed content details. Like the first one has 4 streams and contains a file name, a fork with data, a JPEG data stream and the SIZE information. In the streams all the unprintable characters are printed as dots.

After the function was executed, the plugin shows the error code and the result. For the error codes we know a few and can show the error type. For the result as for parameters the content is shown so you see exactly what is returned.

So we hope this command helps you. Especially with looking for bugs in scheduled scripts on a Filemaker Server.

Filemaker: Export Text to File

Thursday 08 November 2012 at 10:18 pm
In Filemaker you sometimes want to export text. For that people usually use the Export Field Contents script step in Filemaker. There you can specify a field and a filename. Filename can include variables and specify different paths on Mac and Windows. Field can be a field you select or the current field. If you export a container, you get the file written there (make sure you have right extension!) and for text it writes an UTF-16LE encoded text file.

Now sometimes you need more. Like you want to export values in a variable without putting them in a field. You may want to export text as UTF-8, MacRoman, Windows ANSI or some other text encoding instead of UTF-16LE. With String.WriteTextFile you can specify the text encoding you want. Maybe you want to pass text before through String.ReplaceNewline to make sure the right newline character is used. For example CR for Classic Mac, CRLF for Windows or LF for Unix Mac OS X. Next you may want to write a log file and just append to a file with String.AppendTextFile.

For containers you can export them with Container.Export. There you can specify a container as field or variable and a path to write to. And you select what to export. Like if your container contains a TIFF picture, you can either export the TIFF or the preview JPEG. The function Container.GetTypes tells you which types are in a container.

If you like, please check Container.Export, String.AppendTextFile, String.WriteTextFile or String.ReplaceNewline.

MBS Filemaker Plugin, version 3.0pr7

Tuesday 06 November 2012 at 1:38 pm
New in this prerelease of the 3.0 plugins:
  • Changed SyntaxColoring.AddTag function to take a new selector parameter to specify what to color: function, scriptstep, variable or formula.
  • Added SyntaxColoring.Enabled function.
  • Added Container.GetName function.
  • Added Container.Rename function.
Download at monkeybreadsoftware.de/filemaker/files/Prerelease/.

Archives

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