Troi URL Plug-in can help you communicate with a web server. Communicating with a web server is done with the help of status codes. You will find an overview of the possible HTTP status codes here: https://en.wikipedia.org/wiki/List_of_HTTP_status_codes.
Some of those may be returned by Troi URL Plug-in.
Updated file management plug-in for FileMaker Pro 16 improves Drag and Drop function
In this post you find the older release notes for Troi File Plug-in for FileMaker Pro.
Troi File Plug-in 11.0.2 (for FileMaker 14 to 18) (September 10, 2019)
- Tested and improved the compatibility with the upcoming macOS 10.15 (Catalina).
- (macOS Catalina) Fixed a bug in the Show Select Folder Dialog script step and the TrFile_SelectFolderDialog function where selecting the top folder of a disk would result in the diskname with two colons at the end (instead of one), for example “macHD::”.
- (Windows) Fixed a bug in the TrFile_GetContents function, where an error code $$-4212 (kErrReadBytesDiff) could be returned when getting the contents of an empty file.
- Made small improvements to the DataIn.fmp12 example file.
- Updated the text on the layout of the DragAndDrop.fmp12 example, to better show the “-ScrollDropZone” switch.
Troi File Plug-in 11.0.1 (for FileMaker 14 to 18) (June 13, 2019)
- (Windows) Fixed a bug in the Create Folder script step and TrFile_CreateFolder function: the plug-in no longer returns error $$-43 (fnfErr) when creating nested subfolders on a mounted shared disk.
- (macOS) Fixed a problem with creating thumbnails from PDFs with the Create Thumbnail script step or the TrFile_CreateThumbnail function: the plug-in no longer returns error code $$-2003 instead of the thumbnail.
- (macOS) Fixed a possible memory leak when using the drag and drop functionality.
- (macOS) Fixed a bug in the Add DragAndDrop Handler script step and the TrFile_DragAndDrop function where it could return error $$-5600 when running FileMaker Pro 18.
- (Windows) Fixed a bug in the Add DragAndDrop Handler script step and the TrFile_DragAndDrop function when running FileMaker Pro 14, which would cause the script not to be triggered.
- Updated the DragAndDrop.fmp12 example to check for the minimum plug-in version 11.0.1.
Troi File Plug-in 11.0 (for FileMaker 14 to 18) (May 21, 2019)
- Tested and made compatible with FileMaker Pro 18 and FileMaker Pro 17.0.6.
- Added new TrFile_ExportToFile function, which can save container data to disk. This function can also be used on FileMaker Server.
- Added new TrFile_IsFree function, which can be used to determine if a file is in use by a different application (or locked).
- (macOS) Added new Set MetaData of Movie script step, which can set or replace metadata of movie files (like .mov and .mp4). It can add and change metadata like title, GPS and creation date. Note: this works only on macOS.
- (macOS) Added new TrFile_SetMovieMetaData function, which can add (or replace) metadata to movie files (like .mov and .mp4). It can add and change metadata like title, GPS and creation data. Note: this is implemented only on macOS.
- (macOS) Improved TrFile_CreateThumbnail function and the Create Thumbnail script step: you can now create thumbnails of movie files (like mov, mp4 etc). The plug-in creates a thumbnail of the first frame of the movie.
- (macOS) Prepared the plug-in for notarization: the plug-in can now be added to a runtime, to create a hardened FileMaker runtime app which can be notarized by Apple. Notarization gives users more confidence, as the runtime has been checked by Apple for malicious components.
- (Windows) Improved the TrFile_ExecuteShell function and the Execute Shell script step. If you use the switch “-Encoding=UTF8” the plug-in now indicates invalid UTF-8 characters with the string <INVALID UTF8>.
- Improved the ExecuteShell.fmp12 example file, you can now specify the encoding of the result of the command.
Other changes and improvements
- IMPORTANT (macOS only) The minimum supported FileMaker version is now FileMaker Pro 14. Also the minimum supported Mac OS version is now OS X 10.10 (Yosemite). You can keep using v10.2 for older versions of FileMaker Pro or Mac OS X.
- (macOS) The plug-in no longer has the 32-bit code included.
- Improved the initialization when installing the plug-in with the FileMaker Pro “Install Plug-In File” script step.
- Updated the EasyInstallTroiPlugins.fmp12 file, it can show additional error information from Get(LastExternalErrorDetail) when running on FileMaker Pro 18. The EasyInstallTroiPlugins.fmp12 file can also run a test registration script for a plug-in after you have installed it on FileMaker Server.
- Updated the example files for FileMaker Pro Advanced 18.
- Made small corrections to the user guide.
- Fixed a bug in the TrFile_CreateThumbnail function where creating a thumbnail from a RAW file could result in a crash when stopping FileMaker Pro if other plug-ins were also installed.
- Fixed a bug in the TrFile_CreateThumbnail function where creating a thumbnail from a RAW file could result in a hang when stopping FileMaker Pro.
- Fixed a bug in the TrFile_GetMetaData function with the switch “-GetEXIF” where in some cases getting EXIF of a RAW file could result in error code $$-4259.
- (Windows) Fixed a bug in the TrFile_ExecuteShell function and the “Execute Shell” script step, where sections of the result text would not be included.
- (Windows) Fixed a bug in the Launch Application and the TrFile_Launch function which could fail and return an error code $$-1 in some cases when running FileMaker Pro in Windows Server 2012. This bug could also manifest itself with the Reveal functionality of the plug-in.
- (macOS) Fixed a bug in the TrFile_ListFolder function and the “-Recursive” switch, where in some cases the function could randomly fail and return error code $$-120.
- Modernized the Regifunc.fmp12 file, it now demonstrates the cross-platform plug-in registration process.
Version 10.2 (for FileMaker 13 to 17) (March 4, 2019)
- Tested and made compatible with FileMaker Pro 17.0.4.
- (Windows) Fixed a problem where the plug-in would not be loaded on Windows 7.
- (Windows; 32-bit) Modernized the code when using the TrFile_GetMetaData function with the switches “-GetImageDescription” and “-GetMovieDescription”. This functionality now works for most image and movie formats without QuickTime installed.
- (macOS) Improved TrFile_CreateThumbnail function and the “Create Thumbnail” script step: you can now create thumbnails of Photoshop files (with extension .psd).
- Fixed a problem in the TrFile_CreateThumbnail function and the “Create Thumbnail” script step: the plug-in no longer returns error code $$-8994 (noThumbnailFoundErr) instead of the expected error code $$-2003 (cantFindHandler) when no thumbnail could be created.
- Updated the code base, the plug-in now uses more modern C++ libraries.
- (macOS) Removed old code dealing with resources.
- Updated the EasyInstallTroiPlugins.fmp12 file, it can now run a test registration script for a plug-in after you have installed it on FileMaker Server.
- Made small corrections to the user guide.
Version 10.1 (for FileMaker 13 to 17) (January 7, 2019)
- Tested and made compatible with FileMaker Pro 17.0.3.
- Added support for the Windows XP EXIF tags. These are the tags XPTitle, XPComment, XPAuthor, XPKeywords and XPSubject (tags 40091 to 40095):
- Improved the TrFile_GetMetaData function with the switch “-GetEXIF”. The plug-in now returns the WindowsXP EXIF tags correctly.
- Improved the TrFile_SetMetaData function with the switch “-SetEXIF”. You can now write EXIF data with WindowsXP EXIF tags.
- Improved support for EXIF with UTF-8 text:
- Improved the TrFile_GetMetaData function with the switch “-GetEXIF”. You can now get EXIF with UTF-8 encoded strings using the switch “-SourceUTF8Charset”.
- Improved the TrFile_SetMetaData function with the switch “-SetEXIF”. You can now write EXIF with encoded UTF-8 strings by adding the switch “-UTF8Charset”.
- Improved the TrFile_SetMetaData function: it no longer creates an empty destination file when specifying invalid switches.
- Improved the GetStructure.fmp12 file: it now shows a dialog when trying the TrFile_GetFileStructure function with a (old!) QuickTime movie that has its MOOV atom in a resource fork. Note that the TrFile_GetFileStructure currently does not support MOOV atom in a resource fork.
- Improved the DragAndDrop.fmp12 file.
- Improved the All File Examples.fmp12 file.
Version 10.0.1 (for FileMaker 13 to 17) (September 18, 2018)
- Fixed a bug with registering the plug-in on FileMaker Server.
Version 10.0 (for FileMaker 13 to 17) (May 15, 2018)
- Tested and made compatible with FileMaker Pro 17.
- Rewrote and modernized the low level file handling code of the plug-in.
- Added new Exchange Files script step, which can (quickly) exchange two files on disk. With the checkbox “Allow different volumes” you can even exchange files on different disks. Note that this may take more time.
- Added new TrFile_ExchangeFiles function, which can (quickly) exchange two files on disk. When you add the switch “-AllowDifferentVolumes” the plug-in also can exchange files on different disks. Note that this may take more time.
- Added new TrFile_GetCodeSignInfo function, which returns code sign info of signed files (like applications and plug-ins).
- Added new TrFile_GetFileStructure function, which returns the structure of a movie file. It can analyze a movie file (.mov) and return a list of all movie boxes (formerly known as atoms) in the movie. The movie boxes are indented to visualize the tree structure of the boxes. The result can be formatted as XML or as a more readable list of movie boxes. It can also return the structure of a ISOBMFF (ISO base media file format), for example MP4 or HEIC.
- Added new switch “-AllowDifferentVolumes” to the TrFile_MoveFile function, which allows the move of the file between different volumes (disks). Note that moving a big file across disks may take more time.
- The plug-in now indicates if an external script step is compatible with a product. The step is shown in grey if it is incompatible for that product (for example for iOS) in the script editing pane (center) and the script steps pane (right).
- Added new switch “-AddFolderSuffix” to the TrFile_ListFolder function: this will add a trailing slash to folders in the result, making them recognizable as folders.
- Added a new switch to the TrFile_DragAndDrop function: “-ScrollDropZone” to help with the scrolling behavior when you use a drop zone for the drag destination. When you add the switch the position of the dropzone will scroll too when scrolling the FileMaker window.
This is also implemented in the script step “Add DragAndDrop Handler” with the checkbox “Scroll the drop zone”.
Improved metadata support
- Improved the TrFile_SetMetaData function with the switch “-SetEXIF”. The plug-in is now compliant with EXIF v2.3.1. It writes tags introduced in EXIF version 2.3.1, like LensMake, LensModel and LensSerialNumber and timezone tags. The plug-in also handles these tags: ambient temperature, humidity, pressure, waterdepth, acceleration, sensitivity type, standard output sensitivity, recommended exposure index. Finally the plug-in handles the GPS tag GPSHPositioningError, which indicates horizontal positioning errors in meters.
- Improved the TrFile_SetMetaData function with the switch “-SetEXIF”. The code has been rewritten and the plug-in now writes EXIF data that is better readable by PHP.
- Added more tags to be written when using the TrFile_SetMetaData function and the switch “-SetEXIF”: the plug-in now correctly writes the tags: WhitePoint and PrimaryChromaticities. It now also writes tags which are not part of the EXIF specification, but may exist in the EXIF data in some images. This can be tags like ProcessingSoftware or DocumentName.
- (macOS) Added initial support for HEIC (High Efficiency Image File Format) image files: the TrFile_GetMetaData function with the switch “-GetImageDescription” now returns a description.
Other improvements and changes
- Improved handling of files located on remote volumes like WebDAV.
- Fixed a problem with the TrFile_Exists function, where certain incorrect paths with double colons would result into a 1 as result.
- Improved the TrFile_DragAndDrop function so that it works with FileMaker Pro 17.
- (macOS 10.13.4) Fixed a problem with the TrFile_DragAndDrop function when using the switch “-AllowMailDrops”, where an incorrect path to the temporary email file would be returned. The plug-in now returns the correct path. In some cases the Mail app does not create the temporary email file, the plug-in then returns the complete drag information, which can be parsed to get the correct location of the email.
- Added example script to the SelectFile.fmp12 example file which demonstrates how to use the switch “-HideInvisibles”.
- (macOS) The minimum supported Mac OS X version is now 10.8.
Version 9.1 (for FileMaker 12 to 16) (February 20, 2018)
- Added new TrFile_ResolveAlias function, which will resolve an alias file (on macOS) or shortcut (on Windows). It returns the path to the destination of the alias file. If the alias is broken you can use the switch “-ReturnLastKnownPath” to get the last path the alias pointed to.
- Added extra switch “-AddAliasInfo” to the TrFile_GetTypeOfItem function. If an item is an alias file (or shortcut on Windows) the result will be “file (alias)”.
- You can now add the “-DontResolveAlias” switch to the TrFile_SelectFileDialog function. When you select an alias/shortcut the result is the path to the alias itself (and not the destination path where the alias points to).
- (Windows) Added code signing to the plug-in for Windows (On macOS code signing was already added in version 8.0).
New functionality for movie metadata
- Added new functionality to the TrFile_GetMetaData function: when using the switch “-GetMovieMetadata” the plug-in now returns all metadata embedded in QuickTime movies (with extension .mov) and all variants of MP4 movies. This returns a list of metadata in the movie, returning for example Artist, Creation date and Description.
- Added new functionality to the TrFile_GetMetaData function: when using the switch “-GetMovieGPS” the plug-in now returns the GPS location data of the movie. With an extra -Format switch you can specify how the location is returned:
Format switch Description Example -Format=Decimal Decimal coordinates (default) +52.0907 +5.1213 +112.000 -Format=DegMinSecs Latitude, longitude (in degrees,
minutes and seconds) and height (in meters)
52° 05′ 26.5″ N, 5° 07′ 16.7″ E, 112m -Format=ISO6709 Formatted according to ISO 6709 52.0907+5.1213+112.000/
- Added new switch “-GetMovieCreationDate” to the TrFile_GetMetaData function: when using this switch the plug-in returns the creation date (including time + timezone) of the movie (if present as metadata). This might return for example: “2018-01-31T16:29:07+0200”
- Added new functionality to the TrFile_GetMetaData function: when using the switch “-GetXMP” the plug-in now can read embedded XMP metadata in movies. The plug-in supports reading XMP metadata for QuickTime movies (with extension .mov) and all variants of MP4 movies.
- Improved the example file ManageMedia.fmp12, it now demonstrates how to retrieve metadata from movies (including XMP).
- Improved the TrFile_GetMetadata function. Added new switch “-SourceUTF8CharSet”, to be used with the switch “-GetIPTC”. The IPTC metadata of the source image file will forced to be read as UTF-8 encoded.
- Updated the FileManipulation.fmp12 example file to show the TrFile_ResolveAlias function.
- (Mac OS) Fixed a possible bug in the TrFile_Substitute function, when substituting in place: there are no longer spurious extra characters at the end of the new file when the replace string is shorter than the search string.
- In the TrFile_Substitute function, when the search string is at the end of the source file the destination now has the correct end character.
- (Mac OS) Fixed a bug in the TrFile_Substitute function on macOS 10.13 (High Sierra): when you substitute in place this no longer gives an $$-50 error code as result.
- (Mac OS) Improved the reliability of the TrFile_SetMetadata and TrFile_InsertContents functions on macOS 10.13 (High Sierra).
- (Mac OS) Fixed a possible memory leak in the TrFile_GetFolderSize function.
- (Mac OS) Fixed a compilation problem with code signing and extended attributes in macOS 10.12 (Sierra).
Version 9.0.1 (for FileMaker 12 to 16) (June 19, 2017)
- (Windows) Fixed a bug with the TrFile_DragAndDrop function which prevented drag and drop when running FileMaker Pro 16.
- Improved the DragAndDrop.fmp12 example file: the calculation for the bounds of the three drag zones are improved when running FileMaker Pro 16.
Version 9.0 (for FileMaker 12 to 16) (May 9, 2017)
- Tested and made compatible with FileMaker Pro 16.
- Added new TrFile_GetFolderSize function, which can get the total size (in bytes) of a folder.
- Added new TrFile_AppendContentsToFile function, which can append text to the end of a specified (text) file.
- Added new TrFile_SetContentsOfFile function, which can set the contents of a specified (text) file.
- (Mac OS) Added new TrFile_SetFinderComment function, which can set the text of a Finder comment (also called Spotlight comment) of a specified file or folder. You can see the comment with the Get Info command in the Finder.
- Renamed the TrFile_MetaData function to TrFile_GetMetaData, as to better reflect its functionality.
- Added possibility to use a container as the source parameter for the TrFile_GetMetadata function.
- Improved the TrFile_DragAndDrop function: you can now specify three different drop zones with the TrFile_DragAndDrop function.
Extra features when running FileMaker Pro 16
- The File Plug-in adds multiple script steps when running FileMaker Pro 16.
You can select these script steps in the script steps pane in Script Workspace, or you can begin typing the script step name, then choose the script step from the list that appears.
The script steps significantly expand the possible actions you can perform with FileMaker Pro. The following 36 script steps are added:
- Append to File
- Get File Contents with Dialog
- Enable/Disable Troi File Plug-in
- Copy File
- Copy Folder
- Create Alias
- Create File
- Create Folder
- Create Thumbnail
- Create Zip
- Delete File
- Delete Folder
- Add DragAndDrop Handler
- Execute Shell
- Insert in File
- Launch File
- Launch Application
- Mount Disk
- Move File
- Move Folder
- Open Folder
- Reveal File
- Reveal Folder
- Show Save File Dialog
- Show Select File Dialog
- Show Select Folder Dialog
- Set Contents of File
- Set File Attribute
- Set Finder Comment
- Set MetaData of Image File
- Set Timestamp Created
- Set Timestamp Modified
- Stop DragAndDrop Handlers
- Substitute In File
- Unmount Disk
NOTE Only steps that perform an action have been added as a script step. Functions that just return information (like for example TrFile_GetFileSize) are only available as an external function.
- Added new example file CreateFile-for-FMP16.fmp12, which demonstrates how to use the new external script steps of FileMaker Pro 16.
- Added support for online help for the functions and script steps of the plug-in. You can now easily get online help from the Troi website, by clicking the Help button (the small question mark button) next to the function description in the functions pane or the script step description in the script steps pane.
- (Mac OS X) Fixed a problem with the TrFile_DragAndDrop function when dragging mail: email messages with a semicolon (“;”) in the subject of the email are now handled properly.
- Several bug fixes and further improvements.
- Updated the Attribute.fmp12 example file.
- Made various minor changes to the example files to better work with FileMaker Pro 16.
- Updated the code by adding improved namespace handling to make the plug-in more robust.
Version 8.6.1 (for FileMaker 12 to 15) (January 20, 2017)
- (Windows) Improved the handling of certain ZIP files with the TrFile_UnZIP function: the plug-in will now implicitly create a folder when items in the ZIP file are in a subfolder, but that subfolder itself is not present.
- Improved TrFile_MetaData( “-GetPDFDescription”): the plug-in can now better parse newer PDF versions, like PDF 1.7. And if there is a parsing error the plug-in returns the partial data.
- (Mac OS X) Improved TrFile_MetaData( “-GetMovieDescription”): when a movie contains a Timecode track, the Timecode at the beginning and end of the movie and the Timecode of the current frame is returned again as part of the description.
- Improved the multi-threading behavior of the TrFile_Metadata function. Multiple running scripts on FileMaker Server at the same time will now work better.
- Improved the multi-threading behavior of the TrFile_Substitute function. Multiple running scripts on FileMaker Server at the same time will now work better.
- Fixed a memory leak in the TrFile_Substitute function.
- Fixed a bug in the TrFile_SetContents and TrFile_AppendContents functions where extra spurious characters could be written. This could happen when a text which contained combining unicode characters (for example a combining diaeresis, combining to ä) was written to a file using encoding: -Encoding=ASCII_Windows.
- (Mac OS X) Improved stopping of the drag and drop handling and removed a potential memory leak.
- (Mac OS X) Fixed a potential crash in the TrFile_DragAndDrop function, when restarting drag and drop multiple times.
- (Windows) Added an exception handler, which handles (fatal) exceptions in the plug-in. It will save information on the exception to a dump file in the Temp directory. The dump file will be named similar to this:
“Crashdump Troi File Plug-In v8.6.1-20161231-212603-5488-3164.dmp”.
When running FileMaker Server the plug-in also writes the exception in the “Troi Plugin FMServer.log”:
- 2017-01-01 21:26:03 [Troi File Plug-In] Exception raised. code = -1073741819
- 2017-01-01 21:26:03 [Troi File Plug-In] Created crash dumpfile:
C:\Users\user\AppData\Local\Temp\Crashdump Troi File Plug-In v8.6.1-20170101-212603.dmp
- 2017-01-01 21:26:03 [Troi File Plug-In] **** FATAL ERROR: EXIT PROCESS ****
- (Mac OS X) Improved export of symbols: now only the symbols that are required are exported by the plug-in.
- Improved the internal registration of function calls of the plug-ins, making it more robust on more platforms.