Conversion of Troi Dialog Plug-in from FileMaker 6(This page was last updated July 18th, 2006.)NOTE This document was created in 2006 and is intended for conversion from FileMaker Pro 6 to a later version of FileMaker Pro.
It is not updated anymore but the principles discussed here should be fine.
Below we will discuss Troi Dialog Plug-in 4.0, but this also should apply to future versions with a higher number, for example version 4.5. TIP Although you can use both Troi Dialog Plug-in 3.6 and Troi Dialog Plug-in 4.0 together when running FileMaker 7, this is not recommended. Please only use Troi Dialog Plug-in 4.0 for FileMaker Pro 7 and . Please only use Troi Dialog Plug-in 4.5 for FileMaker Pro 8 and 8.5. Troi Dialog Plug-in 3.6 is compatible with FileMaker 7Troi Dialog Plug-in 3.6 in general does work with FileMaker Pro 7, without modification. We have found no other issues with FileMaker 7 than the ones below. Delay in visibility of the TrDl-ProgressBar functionFileMaker Pro 7 has a subtle change in how it handles plug-ins. This results in a delay in showing the contents of the progress bar. You will first see the dialog window, without any text and progress bar drawn in. After a short delay it will show the correct contents. To improve this: Add an extra Pause/Resume step of 0 seconds after the 'show' step. This will cause the progress bar and text to be directly visible. See the updated example file. Modify scripts which set a custom iconThe current version of FileMaker 7 seems to have a bit of delay in updating a the clipboard, after you have used the Copy script step. This will result in a $$-4239 error (kErrClipboardNotOpen) from the TrDl-IconControl function of the plug-in. This error occurs only on Windows. To prevent this you must change the scripts with the TrDl-IconControl function. If for example you have this script in a FileMaker Pro 7 file: Copy[ Select ; gCustomIconField ] You need to change it to: Copy[ Select ; gCustomIconField ] This will pause FileMaker long enough to get the icon on the clipboard. See also the fp7 example files of Troi Dialog 3.6, which have this modification applied. General Issue for all Classic plug-ins with higher ASCII'sFileMaker Pro 7 has a new internal architecture, which is using Unicode for the text fields. FileMaker Pro 6 only used ASCII encoding. ALL plug-ins written for the 'classic' FileMaker 6 architecture do not receive characters that are outside this ASCII range, these characters are replaced with spaces. In general our plug-ins should be compatible as long as the text used is lower ASCII text. The Dialog Plug-in 3.6 is using the classic API, so only characters in the ASCII range will work. Previous versions of Troi DialogWe have tested version 3.5.2 and version 3.5.3 with FileMaker 7 and this works similar as version 3.6.
We have not tested earlier versions, but we expect versions 3.5.1 or
older of the plug-in to work with FileMaker 7, however this
latest version has some bug fixes too, so it is strongly
recommend that you use the latest version.
Troi Dialog Plug-in 4.0 (Native FileMaker 7 API)Troi Dialog Plug-in 4 was created specifically for FileMaker Pro 7. Below are some considerations when converting to Troi Dialog Plug-in 4. New function syntaxThe plug-in functions have a different syntax compared to the FileMaker 6 plug-in. For example the Dial_Dialog function has this syntax in the classic API: External("TrDl-DialogEx", "switches|text|button1|button2|button3|button4" ) The syntax in the new API looks like this: Dial_Dialog(switches ; Note that functions look like a real function call, no longer a call to External(). Also a hyphen "-" is no longer allowed in the function name, so the hyphens have changed to underscores "_" instead. Note too that parameters don't have to be concatenated with a pipe. Instead use a semicolon ";" to separate the parameters. The brackets "{}" indicate optional parameters. Below is an example how this function would appear in ScriptMaker: Set Field [result , TIP Function names are no longer case sensitive and will change to the correct case after you close the "Specify Calculation" dialog box. Multiple parameters and new switchesAs seen from the syntax, plug-in functions now can have multiple parameters. To make this plug-in more consistent, all functions now have a switches parameter as the first parameter. This makes enhancing the plug-in in the future easier. Finally we renamed a few functions and also removed any spaces in the name. See the specific functions notes below for the specifics. TIP Switches are not case sensitive. Omitting optional parametersWhen you omit an optional parameter be sure to add an extra semicolon after the last one, otherwise FileMaker will show an alert that there are too few parameters in this function. For example, below we omitted the 5th and 6th parameter at the end (button3 and button4). This is the correct way to do this: Set Field [ result, New parameter limitsThe plug-in functions now have a size limit of 1 Gb per parameter (up from the total of 64000 character limit for all parameters in FileMaker 6). The Troi Dialog Plug-in 4 in general can handle bigger parameters, however not all dialogs have the room to display these long text. Converting the function callWhen converting FileMaker does not change the plug-in call. So after conversion you need to do this manually. Here are the global steps:
Let's for example take this Troi Dialog Plug-in 3.6 call: External("TrDl-DoFlashDialog", "360|Hi, This is a Flash Dialog.") ) This needs to be changed to this Dialog Plug-in 4 call: Dial_FlashDialog( "-Unused" ; 360 ; "Hi, This is a Flash Dialog.") TIP You can just copy script or steps from the example files of the Dialog download, they are all in the Dialog Plug-in 4 format! Renamed functionsThe table below will help you figure out the new names for changed function names:
Specific functions notesAll functions of Troi Dialog Plug-in 4 fully support Unicode, unless noted otherwise. The table below lists conversion issues with specific functions:
Unicode SupportMost of the functions of Troi Dialog Plug-in 4 fully support Unicode. The table below lists Unicode support for each function of the plug-in:
Please report problems and bugsIf you find any other problems or bugs, not mentioned
above, please send an email to: info@troi.com.
Please do NOT send attachments unless specifically
requested. Please include the FileMaker Pro version, your
platform and operating system in your comments. |