Technical Brief
FileMaker Go 1.2.1 Technical Brief
24
berareforsomeone“intheeld”toneedtorunlargebatchscripts.Whileaconcern,andsomethingthistechnical
brief addresses, the practical reality is that developers will accommodate the limitations of mobile networks.
Developers should consider leaving the heavy lifting to FileMaker Pro users and FileMaker Server.
Scripting Strategies
There are a few different ways to approach data processing scripts for mobile or, more universally, WAN-accessed
databases. The following techniques are meant to illustrate the ideas without necessarily suggesting that these are
the only or universally correct approaches.
Testing for Platform
There is no additional permission required to open a database in FileMaker Go; this is an important subtlety to
understand. If users have permission to open a file in FileMaker Pro, they can also open the file in FileMaker Go.
Given that complex database solutions are likely to contain scripts that need to be tested before being used in
FileMaker Go, you may want to prevent mobile users from connecting to your database until you have checked for
compatibility.
As mentioned above, you can test which platform someone is using by using the calculation function
Get(ApplicationVersion).TheiPhoneandiPodTouchwillreturn“Go1.x.x”andtheiPadwillreturn“Go_iPad1.x.x”.
You can also use the Get(SystemPlatform)functionwhichwillreturnaresultof“3”whenevaluatedfromamobile
device using FileMaker Go.
If you add an If step to a script set to run when your database opens, you can effectively prevent mobile users from
accessing the database:
If [ Get ( SystemPlatform ) = 3 ]
Show Custom Dialog [ Title: “Mobile Access”; Message: “This database does
not yet support access by FileMaker Go. Please contact your developer for
further information.”; Buttons: “OK” ]
Close File [ Current File ]
End If
OnTimer Scripts
OnTimer triggered scripts are set to run at specified intervals. A key difference between a script set to execute with
an OnTimer trigger and any other script is what happens when a user hits the Home button or a call comes in and
forces FileMaker Go to close. A script being triggered with the OnTimer script step is smart enough to know how
much time has elapsed even though the application may have been closed. Once the application is reopened, the
OnTimer script will know if the interval has passed and will trigger the script in the event that it has.
For example, if you managed your daily appointments using FileMaker Go and had a reminder set to alert you
10minutesbeforeanappointment’sstarttime,youcoulduseanOnTimerscripttohelpFileMakerGokeeptrack
of your reminders even if a call comes in. No other trigger or scripted process can continue in the event that
FileMaker Go is closed. In addition to the OnTimer script, you need to make sure that you add an Allow User Abort
[Off]scriptstepinyourscript.IfyoudonotaddanAllowUserAbort[Off]scriptstep,thenthescriptwillabort,and
the OnTimer script will cease to function until you are able to trigger it once again. This technique demonstrates
one of many possible uses for an OnTimer trigger using FileMaker Go.