Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 6885 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I would like to be able to set a script to export to a file name based on a particular field (username using the get function). Is this possible?

Posted

Yep. Create the full path & file name in a variable and use the variable in the "specify output file" window of the export script step.

Only the variable should be listed there, no calculation.

Note though:

- the path must exist already, FM can't create a folder

- the path syntax has to follow the FM path syntax rules, not the OS's syntax. Syntax is different for Mac and Windows so you may need to branch your code according to the platform.

Posted

Yep. Create the full path & file name in a variable and use the variable in the "specify output file" window of the export script step.

Only the variable should be listed there, no calculation.

Note though:

- the path must exist already, FM can't create a folder

- the path syntax has to follow the FM path syntax rules, not the OS's syntax. Syntax is different for Mac and Windows so you may need to branch your code according to the platform.

Thanks. So do I simply create a field to calculate the path and just type the field into the "specify output file" window of the export script step?

Posted

I got part of this working. I was able to get FileMaker to export the file to the correct location using a variable to define a path as described above by Wim Decorte.

However, in a subsequent step in my script, I'm using an AppleScript to then open the file using SimpleText under Classic (we have a specific need for this versus it opening in TextEdit). How can I specify the same variable in AppleScript? Just adding the variable to it doesn't work.

This topic is 6885 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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