Naming Pattern

Post Reply
anon69
Newbie
Posts: 15
Joined: Wed Jun 12, 2013 9:59 am

Naming Pattern

Post by anon69 »

hello, im currently trying to rename a few documents using pitstop. i created an action script so that i could use the document name as the title. the problem is that the script also attaches the .pdf extension to the title. is there any way to avoid this? hopefully from within the script and not manually because i just got done doing about 30 files and im irritated. thanks for any and all help.
User avatar
gabrielp
Advanced member
Posts: 577
Joined: Fri Aug 08, 2014 4:31 pm
Location: Boston
Contact:

Naming Pattern

Post by gabrielp »

Excuse my ignorance, but you have a script in Switch you're trying to get the file name of without the prefix? If so, that's called FileNameProper.



In your script:

function jobArrived( s : Switch, job : Job )

{

var fileNameProper = job.getNameProper();

}



In designer "Define text with variables":



[Job.NameProper]
Chat: open-automation @ gitter
Code: open-automation & dominickp @ GitHub
Tools: Switch, Pitstop, EPMS, Veracore, PageDNA, SmartStream, Metrix
anon69
Newbie
Posts: 15
Joined: Wed Jun 12, 2013 9:59 am

Naming Pattern

Post by anon69 »

gabrielp wrote: Excuse my ignorance, but you have a script in Switch you're trying to get the file name of without the prefix? If so, that's called FileNameProper.



In your script:

function jobArrived( s : Switch, job : Job )

{

var fileNameProper = job.getNameProper();

}



In designer "Define text with variables":



[Job.NameProper]




thanks for the help gabrielp! im actiually using action scripts from pitstop pro.
Post Reply