Change file name while saving with actions/macros.
Copy link to clipboard
Copied
Hey all,
I'm setting actions in Illustrator to save multiple file formats of the same file to streamline workflow.
Is there any way to add to a filename using/while using the actions?
Ex:
Saving business card designs I need to save five PDF files:
Front
Front w/o crop marks
Back
Back w/o crop marks
and Full art.
Is there a way to add the description to/modify the file name within actions?
So if the original name is:
Client_BC
I can run the action and it will auto save
Client_BC_Front.pdf
Client_BC_Front_NoCrop.pdf
Client_BC_Back.pdf
Client_BC_Back_NoCrop.pdf
and
Client_BC.pdf
??
Does that make sense?
Any and all help is very appreciated.
Thanks!
Explore related tutorials & articles
Copy link to clipboard
Copied
Actions do not have any conditional functionality. They are a rigid set of instructions. Occasionally, depending upon the task, you can change the course of the action with dialogs that open during execution, but for the most part, however you perform the action the first time, is how the action will be performed all subsequent times.
As far as saving a file, i think you're stuck. If you use the "Save" command during an action, any files on which you run the action in the future will simply be saved in whatever location they were opened from with the existing filename. And if you use the "Save As" command, any subsequent file will be saved into the location you chose when you created the action and it will have the same name as you initially chose as well.
I have gotten around this in the past by creating a blank folder on my desktop and then simply having action(s) that save files into that folder with a sort of generic template name. for example, it would save a file into the folder with the file name: _order_number_Front_NoCrop.pdf
Then after running the action i would open that folder, rename it as necessary and move it into it's correct location. Obviously this is not ideal. The functionality you're looking for should be done with a script instead of an action, as scripts have exponentially more flexibility and power when it comes to this kind of task.
If you're open to a scripting solution, I can gladly help out with that as well.
Good luck.
Copy link to clipboard
Copied
"I have gotten around this in the past by creating a blank folder on my desktop and then simply having action(s) that save files into that folder with a sort of generic template name. for example, it would save a file into the folder with the file name: _order_number_Front_NoCrop.pdf"
That's exactly what I'm doing. I have a folder titled "Working Docs" and all of the formats get saved in subfolders there, then copied over to the client folder and replaced with an empty set of the same name. Of course in typing that I realize that I could just as easily create folders named after the variants and just use straight actions... something I didn't think of before.... *facepalm*
BUT: the fewer folders the better, typically.
Another forum member posted a stack exchange link (scripting) regarding this, so I think I'll take a look into that, just for the hell of it. I'll let you know if I need help with the scripting.
Thanks for the response!
Copy link to clipboard
Copied
Did you find a solution for this? If so could you please share? Thanks!
Copy link to clipboard
Copied
I was going to say that Asset Export almost gets you all the way there, but this would require that you keep renaming these assets each time and would only save the time on choosing the export formats. So, using actions you can probably use them with dialogs, each time making you rename the things, which isn't good either by any means.
You want to learn to do some scripting?

