Jump to content

Dynamic file names


Guse
 Share

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

Recommended Posts

I'm hoping that this is the right subforum for this, if not I apologize.

We have a simple script designed for saving to a PDF. Essentially, it takes the form, saves it to a PDF. We just use the "Save Records as PDF" script step to accomplish it.

Unfortunately, it forces us to use the same name for the file every time. Is there any way to use a variable or field name as the name of the exported file?

Right now, we have something like: filewin:/C:/Documents and Settings/user/Desktop/NEPSpdfs/nepsrecord.pdf

There HAS to be a way to do this....

Link to comment
Share on other sites

FileMaker 8 owners can use the new script variables feature to create dynamic paths for PDFs or any script step that uses the specify path dialog. I have pasted the download URL of an example from my web site demonstrating this technique.

Macintosh download:

http://www.filemakerpros.com/SAVEDYN.sit

Windows download:

http://www.filemakerpros.com/SAVEDYN.zip

Edited by Guest
Link to comment
Share on other sites

Hi Guse:

Use the Set Variable script step.

Name: $MyVariable

Value: MyPDFname (field or calculated value)

Repitions: 1

Use the Save Records as PDF script step.

Specify output file :$MyVariable

Specify options:current record

The above sample will create individual pdf's of each record in your database with a unique name supplied from the MyPDFname field.

Of course you may want a specific path field as well.

Cheers

Edited by Guest
Link to comment
Share on other sites

This topic is 5695 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
 Share

×
×
  • Create New...

Important Information

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