Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

File paths, container fields and applescript

Featured Replies

Hallo

I'm trying to automate the process of inserting word documents into container fields (reference only) using applescript and I'm missing something.

If I use

set file_path to (choose file) as string

and later

set the cell "Pathname" to file_path

the container holds the pathname as a string and wont launch the file on manual entry/ double click to the field

If I use

set file_path to (choose file)

or

set file_path to (choose file) as alias

Then later

Applescript "Gets an error.. Filemaker cant set ...etc etc"

Any thoughts or assistance greatly appreciated.

Thanks

Simon

AppleScript and FileMaker are telling you the truth. You can't Insert File with AppleScript, as far as I know. You have to copy or move the file to a fixed location and name, where FileMaker can then Insert File, using its fixed File Reference.

This is a modified version of an earlier file I posted, which first zipped the file before using Insert File. This one just Inserts it as is. It uses the Unix "ditto" command (which can also zip it) to copy the file to the "temporary items" folder (where it is later deleted).

Warning: If you have file on the desktop with the same name as the file name in the FileMaker field, exporting will replace it, with no warning, and no change of modification date; such as an updated version of the inserted file. Gone forever. One could write a warning I suppose. But I must go make coffee now :-]

InsertFileTI.zip

  • Author

Fenton,

Many thanks for that

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.