A SERVICE OF

logo

52 FileMaker Pro Advanced Development Guide
If the idleLevel parameter is not zero, then the routine has been called
while the application is running a script or is being controlled by the
user. One of the following four messages has been sent:
Do not perform any lengthy, user interface, or event processing when
the
idleLevel parameter is not zero.
The Idle message will also be sent is when the application detects free
time and does its own internal idle handling.
Preferences message
The Preferences message, kFMXT_DoAppPreferences, is sent in
response to a user clicking the Configure button for the selected plug-
in in the Preferences dialog box.
The plug-in should display a dialog box that will allow the user to set
any specific configuration data required by the plug-in. If the plug-in
requires user-definable preferences, you should implement your user
interface here. The
Configure button will only be enabled if the sixth
character of the option string is set to “Y.” For more information, see
“Option string syntax” on page 49.
Any options that need to be saved should be placed in their own
registry entry (Windows) or in their own preference file (Mac
OS X).
The FMExample plug-in needs to implement a configuration dialog
box for the
XMpl_UserFormatNumber function, so the flag has been set
in the option string (
Xmpl1Ynnnnn) and the function Do_PluginPrefs is
called when the Preferences message is received.
External Function message
The External Function message, kFMXT_External, is a legacy message
for old style plug-ins. It is no longer required for plug-ins that are
registered in the new style.
GetString message
The GetString message, kFMXT_GetString, is sent to the plug-in when
FileMaker Pro, FileMaker Pro Advanced, FileMaker Server, or
FileMaker Server Advanced want to retrieve one of the following
strings from the plug-in. The plug-in developer can decide where to
store the strings.
Avoiding potential Mac OS X
resource conflicts
Problems can occur on Mac OS X machines if your plug-in has the
same ID for a resource that FileMaker
Pro, FileMaker Pro Advanced,
FileMaker Server, FileMaker Server Advanced, or another plug-in
has for the same type of resource.
Message Meaning
kFMXT_UserNotIdle = 1 The user has done something within the last 30
seconds.
kFMXT_ScriptPaused = 2 The user is running a script that has been
paused.
kFMXT_ScriptRunning = 3 The user is running a script.
kFMXT_Unsafe = 4 Same as if the unsafeCalls parameter is set to
true.
Message Meaning
kFMXT_UserIdle = 0 The user hasn’t done anything within the last
30 seconds or more.
String Meaning
kFMXT_OptionsStr = 131 The option string
kFMXT_NameStr = 128 The plug-in name
kFMXT_AppConfigStr = 129 The help text to display in the Preferences
dialog box