When you are automating exports of user data from a FileMaker file, the easiest place for the user to be able to find the exported file at a later date is on the desktop. How can you export a file there? Using the Get(DesktopPath) script function!
It returns the path to the desktop folder with a trailing slash ready for you to append a filename to, for example:
$file = Get(DesktopPath) & “export.xml”
Would return something like ‘/C:/Documents and Settings/Username/Desktop/export.xml‘ on a Windows machine and something similar to ‘/MacintoshHD/Users/Username/Desktop/export.xml‘ on a Mac.
If you save it to a variable you can then use it in an export path to enable dynamic export paths to the user’s desktop, without having to know their platform and system username.



August 20th, 2009 at 2:18 am
Easy to get the desktop path in local variable, but you dropped the ball on how you get it into the export path. Please explain fully.
August 26th, 2009 at 7:51 pm
Once you’ve created the variable, you can just use that in the file path calculation for the export