MBS FileMaker Plugin, version 5.2pr5

Sunday 28 June 2015 at 12:47 pm
New in this prerelease of the 5.2 plugins:
  • Changed Text.WriteTextFile and others to better handle null characters in text.
  • Fixed bug in GMImage.NewFromBase64.
  • Changed syntax coloring to not color text black unless we have something to format like a bracket. This way you should normally not see syntax coloring in field picker.
Download at dropbox.com or ask for being added to the dropbox shared folder.

MBS FileMaker Plugin, version 5.2pr4

Wednesday 24 June 2015 at 8:10 pm
New in this prerelease of the 5.2 plugins:
  • Fixed copy button to copy even lines not currently visible in FileMaker 14.
  • Fixed an issue with Dialog functions where Dialog.SetButtons overwrote on Mac the buttons.
  • Added EventMonitor functions to check if which button the last mouse click used.
  • Fixed ProgressDialog.Show to reset Cancel flag on Windows, too.
  • Changed ServerSocket.SendQuery to have a 3 second connect timeout.
  • Added AVAsset functions to use OS X functions for getting images and metadata for movies.
  • Changed CURL to set Verbose option on by default.
  • Updated DynaPDF to version 3.0.40.119.
  • Added SystemInfo.IsAdminUser function.
  • Added CURL.GetResultAsContainer function.
  • Added new mode to CURL.GetResultAs* functions to use the file name from URL if you don't provide one.
  • Fixed indexed for parameters to WebView.Screenshot function.
  • Added Text.InvalidCharactersForEncoding function.
Download at monkeybreadsoftware.de/filemaker/files/Prerelease/ or ask for being added to the dropbox shared folder.

WMI queries in FileMaker

Wednesday 24 June 2015 at 3:44 pm
The Windows Management Instrumentation has the nice feature to run SQL like queries against the database with all the system information. For next MBS FileMaker Plugin now has functions to query those configuration database. Like this example database:



As you see we connect to local computer's namespace (root\cimv2) and run the query "select * from Win32_Printer" to query all properties for all printers. Than our example database will walk over all records found and put all fields with name, type and value. Like on this screenshot for the printers:



Now the queries you can do include table names like Win32_Processor, Win32_NetworkAdapter, Win32_OperatingSystem, Win32_NTEventLogFile, Win32_NTLogEvent, Win32_PrintJob, Win32_Printer, Win32_LogicalDisk, Win32_DiskDrive, Win32_PhysicalMedia, Win32_SerialPort, AntiVirusProduct, FirewallProduct, AntiSpywareProduct or one of the others Microsoft named.

Guess what you can do with this in your solutions with queries on those!

PS: We also have this for Xojo in our MBS Xojo Win Plugin: WindowsWMIMBS class.

EventMonitor

Monday 22 June 2015 at 4:58 pm
Recently a client tried our menu commands to build a contextual menu. His problem was that the mouse click is consumed and processed by FileMaker and he had no idea which mouse button was used to trigger the button and his script. At the time the script run, the mouse button was up already. No way to ask the operation system what button is down.

To help here we added EventMonitor functions to our plugin. Currently you can use them to only detect if last mouse event was due to left or right mouse button. Your script can query that and know the state of the mouse buttons.

We got three new functions:
EventMonitor.Install to call once at startup to tell plugin to monitor events.
EventMonitor.Clear to clear current state if needed.
EventMonitor.LastMouseClickButton to query last mouse event's mouse button.

Technically we could add more things here like the mouse position at the time of click.
Maybe you have ideas for more cool functions?

Now enjoy all using MBS Plugin to present contextual menus in FileMaker and decide in your script what to do based on the mouse button.

FileMaker Meeting in Kiel and future meetings

Friday 19 June 2015 at 11:00 am
Our FileMaker meeting for Kiel is now scheduled for 26th June 2015.
We have a couple of interested people to join and will look now for a meeting place.

Upcoming meetings and conferences:
User MeetingKiel Germany 26th June
User MeetingReykjavik Island survey
FileMaker Developer ConferenceLas Vegas USA 20th to 23th July
FileMaker KonferenzHamburg Germany 8th to 10th October
FileMaker ConferenceGothenburg Sweden 20th to 21st October
FileMaker ConferenceLyon France 21st to 23rd October

If you want to join our local meetings, please contact me, so I can put you on the list.

MBS FileMaker Plugin, version 5.2pr3

Saturday 13 June 2015 at 6:49 pm
New in this prerelease of the 5.2 plugins:
  • Changed Menu.DefineQuickMenuXML to use the given name in xml as ID reference instead of a number.
  • Added Dialog.SetTimeout for Mac to hide dialog after some time.
  • Plugin builds with Xcode 7 on 10.11 beta. Fixed a few minor problems detected by newer analyze function.
  • Upgraded Xcode to version 6.3.2
Download at monkeybreadsoftware.de/filemaker/files/Prerelease/ or ask for being added to the dropbox shared folder.

SQLite in memory databases

Thursday 11 June 2015 at 09:31 am
Sometimes you need more than an assoziative array in memory (Dictionary for Xojo and for FileMaker.).

Sometimes you may want to look at a SQLite database in memory. It has the big advantage that you can fill it with data and run SQL queries against it to find records of data.

To create a memory database with sqlite you specify a file path of ":memory:".

In FileMaker you call:

MBS("SQL.Connect"; $Connection; ":memory:"; ""; ""; "SQLite")

In Xojo or Real Studio you call with SQLDatabaseMBS class:

db.DatabaseName = "sqlite::memory:"

In Xojo or Real Studio you call with SQLConnectionMBS class:

con.Connect(":memory:", "", "", SQLConnectionMBS.kSQLiteClient)

All data is lost if not copied elsewhere when the application quits or you close the database.

Make a 32-bit FileMaker 14 application

Tuesday 09 June 2015 at 9:06 pm
Need to run FileMaker always in 32-bit independent of the flag in Finder info window and independent of how you launch FileMaker?

One way is to simply remove 64-bit code from FileMaker. If you run in terminal the file command, you see that FileMaker 14 is a 32-bit and 64-bit universal binary:

file ./FileMaker\ Pro\ Advanced.app/Contents/MacOS/FileMaker\ Pro
./FileMaker Pro Advanced.app/Contents/MacOS/FileMaker Pro: Mach-O universal binary with 2 architectures
./FileMaker Pro Advanced.app/Contents/MacOS/FileMaker Pro (for architecture x86_64): Mach-O 64-bit executable x86_64
./FileMaker Pro Advanced.app/Contents/MacOS/FileMaker Pro (for architecture i386): Mach-O executable i386

Now to make it a 32-bit only app, run the following command (one line):

lipo -thin i386 ./FileMaker\ Pro\ Advanced.app/Contents/MacOS/FileMaker\ Pro -output ./FileMaker\ Pro\ Advanced.app/Contents/MacOS/FileMaker\ Pro

This removed 64-bit code and you now have a 32-bit only app:

file ./FileMaker\ Pro\ Advanced.app/Contents/MacOS/FileMaker\ Pro
./FileMaker Pro Advanced.app/Contents/MacOS/FileMaker Pro: Mach-O executable i386

For relative paths to work as above, you need to move in the right folder using cd command in Terminal. Please also make a backup and be aware that any updater will probably restore the app.

PS: Do at your own risk. If something goes wrong you need to reinstall FileMaker 14.

MBS FileMaker Plugin, version 5.2pr2

Monday 08 June 2015 at 4:10 pm
New in this prerelease of the 5.2 plugins:
  • Updated DynaPDF to version 3.0.40.118.
  • Fixed text encoding for JSON.GetArrayItemsAsList.
  • Added Menu.DefineQuickMenuXML function.
  • Added Window.Current function.
  • Added Text.Character and Text.Code functions.
  • Added FM.VariableClearAll function.
  • Added ProcessActivity.beginActivity and ProcessActivity.endActivity.
Download at monkeybreadsoftware.de/filemaker/files/Prerelease/ or ask for being added to the dropbox shared folder.

Microsoft Access?

Saturday 06 June 2015 at 12:55 am
Does MBS Plugin allow to connect to a Microsoft Access database?

Yes, it does.
Use our SQL functions to connect to the database via ODBC on Windows. The Connection string looks like this: "Driver={Microsoft Access Driver (*.mdb)};Dbq=C:\Users\Christian\Desktop\test.mdb". As you see we specify to use the Microsoft Access driver and include the file path to the database file. You can include an user name and a password if needed.

Once connected you can use SELECT SQL command to query tables for values. You can run DELETE, INSERT or UPDATE commands to modify data.

Works in Real Studio, FileMaker and Xojo in my testing here with 32-bit Windows.

Logging in FileMaker

Friday 05 June 2015 at 1:46 pm
Do you look for a way to write log messages?

Using the Log function in MBS Plugin you can write log messages like this:

MBS("Log"; "Hello World")

On OS X you see those messages in the Console.app. For Windows, you can install Microsoft's DebugView application and see also the messages.



This even works fine on the server. On Windows with a FileMaker Server, you can see debug messages in DebugView if you run DebugView application as administrator and enable global Win32 listening.

For FileMaker Server on Mac OS X you can see messages in /Library/FileMaker Server/Logs/stderr file. This is just a text file and you can open it with Console.app to show you incoming log entries.

If you run MBS("Trace"), all plugin calls will also be logged there. This enables you to debug plugin usage by checking if all function calls have right parameter and expected results.

Just added functions

Thursday 04 June 2015 at 6:08 pm
Did you know FileMaker's functions Code() and Char() only work well for characters with unicode code points up to 65535?

Well, now we got MBS Plugin functions to replace them:

MBS( "Text.Character"; Character Number )
MBS( "Text.Code"; Char )

So the function call MBS( "Text.Code"; "😀" returns 128512. If you pass that number into Text.Character like this MBS( "Text.Character"; 128512 ), you get back the smiley.

Coming soon in next prerelease of the MBS Plugin. Or email if you like to try it today.

Greetings from .fmp 2015 in Berlin

Thursday 04 June 2015 at 11:45 am
The .fmp[x]Berlin conference just started with more people than ever.

This is an independent FileMaker related developer conference with over 70 people from 13 countries.

Enjoy it, if you are here :-)

PS: Why didn't the developers in Luxembourg and Swiss make it to the conference?

Disable App Nap, System and Screen Sleep in FileMaker

Wednesday 03 June 2015 at 2:50 pm
If you like to disable FileMaker from sleeping while doing a long operation, e.g. a script to export or import, you can use plugin functions.

We got a couple of ProcessActivity functions. To start an activity you call ProcessActivity.beginActivity with the parameters describing the activity. First you provide the options, e.g. IdleDisplaySleepDisabled or IdleSystemSleepDisabled. This can be combined with an attribute like UserInitiated or Background to tell system if it is important to keep awake (user initiated) or not so important (background activity). The second parameter is a reason which may be showed by the system somewhere.

This function returns a reference number for the activity which can be used to query details or to end activity. To end you call ProcessActivity.endActivity providing the reference number of the activity. Using those numbers we can have several activities running at a time.

Those activity APIs are the recommended way from Apple to keep the system from idle sleep or your app to be put on app nap. While you can also exclude applications from App Nap with a flag in the Finder's info dialog (not possible for FileMaker 14), it's highly recommended to let the app take a nap to save battery power.

Available in 5.1pr2 later this week. Please email us if you need a copy today.

PS: Similar things can be done in Xojo with NSProcessInfoMBS class.

MBS FileMaker Plugin, version 5.2pr1

Monday 01 June 2015 at 5:40 pm
New in this prerelease of the 5.2 plugins:
  • Optimized away some debug details on Windows plugin, saving 100 KB in plugin size.
  • Added parameters for Files.Mount function for showing dialogs while mounting.
  • Fixed issue on Windows where plugin did not load on older Windows versions.
  • Added code to overwrite FileMaker overwriting our drag cursors. So DragDrop.SetCursor does again do its job.
  • Fixed some list functions to not return a newline character on the end if told to do so.
  • Fixed text encoding bug with Text.EncodeToXML function.
  • Changed responses from ServerSocket via HTTP to request client to not cache responses.
  • Fixed Drag and Drop for Emails for OS X 10.10.x where Apple changed it a little bit.
  • Fixed RemoteControl.MouseY function for FM14.
  • Added parameter for DynaPDF.ReplacePattern for alignment.
  • Added Schedule functions.
  • Added Files.FileExtension function.
  • Implemented better caching for calendar objects.
  • Updated DynaPDF to version 3.0.40.117.
  • Changed Windows plugin to no longer link directly to Mpr.dll and Rpcrt4.dll
  • Changed Files.Mount on Windows to load required DLL dynamically, so plugin loads on older Windows versions.
  • Fixed SyntaxColoring.Disable for FileMaker 14 to actually disable script colors.
  • Added SyntaxColoring.CopyButton.GetEnabled and SyntaxColoring.CopyButton.SetEnabled functions to switch copy button on/off.
  • Added "underscore variable name" and "tilde variable name" tags for syntax coloring.
Download at monkeybreadsoftware.de/filemaker/files/Prerelease/ or ask for being added to the dropbox shared folder.

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