How would you identify the newest copy of the file from others? By the "modified date" associated with the file?
If so and if you don't want the user manually selecting the file to insert, you'll need either a plug in or a system script (of which AppleScript is one possibility).
I want the newest modified file so yes by the modification date
Did you have an example of AppleScript that can do that ?
Sorry, but others will have to help you with AppleScript. Haven't used that tool in many years so my info is way out of date.
Thanks for your help
I found a Applescript to do that but can somebody tell me how to pass the value back to Filemaker (from the Perform Applescript in my script) ... i try a lot of combination but nothing seem to work ...
i try these lines on my script
"tell application \"Finder\"¶
set myFolderName to \"" & $lien_pdf & "\"¶
set myFileName to first paragraph of (do shell script \"ls -t \" & myFolderName)¶
set cell \"Projet::TEMP_variable_pdf\" of current record to myFileName as text¶
I was able to get the name of the newest file of my folder without problem, but when AppleScript try to send it back to FileMaker, I always have these errors :