These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Javascript editor keeps popping during batch sequence.

rodolfo
Registered: May 12 2009
Posts: 9
Answered

I have created a simple batch sequence to set the title property to the file name for all the docs in a folder. This is to improve the results from a search engine that returns the title property as its main tag.

However, when I run the sequence, the script editor launches for each doc and requires an ok to continue.

How can I disable this?

script is:

/* set title to file name */
try {
var s = this.documentFileName;
if (s.length > 1) {
var v = s.split('.');
this.info.Title = v[0];
}
} catch (e) {
event.rc = false;
}

My Product Information:
Acrobat Pro 8.0, Windows
try67
Expert
Registered: Oct 30 2008
Posts: 2398
What does it ask you to approve?

- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com

gkaiseril
Expert
Registered: Feb 23 2006
Posts: 4308
Are you saving the updated files to the same directory? If so, you need to approve the over write. If you send them to an empty dirctory you will not be prompted to over write.

George Kaiser

rodolfo
Registered: May 12 2009
Posts: 9
Thanks Gents,

It's just the javascript editor that pops with the batch script in edit - there's no specific confirmation dialog - and I simply have to ok or simply exit the editor to continue i.e. If I have 9 documents in the folder, I get the editor pop 9 times. It completes successfully but I'd prefer not to have to click through 1000 iterations...

Since it is only adjusting a property of the document in scope, there isn't another document ouput so another folder shouldn't really be necessary? - I have Full Control on the folder anyway.

I've also unchecked the "Run Sequence Confrimation" in the Batch Processing properties - although this in theory is unrelated.
gkaiseril
Expert
Registered: Feb 23 2006
Posts: 4308
If you are going to have this data saved in the PDF, and it is a modification of the PDF, you will need to save the PDF.

George Kaiser

rodolfo
Registered: May 12 2009
Posts: 9
Cheers,

Except for the inconveniance of having to exit the editor, the script succeeds in replacing the Title property without formally saving the document object in the script itself.

I'll experiment with saving the document but it seems a bit of an overhead to circumvent the editor app being launched.

It's 9:50 am on Thursday here in New Zealand so I'm guessing you're heading home soon in Chicago - have a nice evening.
rodolfo
Registered: May 12 2009
Posts: 9
All sorted - the sequence was inadvertantly set to "interactive" & the only indication of that is a subtle difference in the icon next to the sequence name in the edit dialog. Apologies for the time-wasting.