Hi,
I would like to run a java script to all open pdf documents. If I try the line below:
oTrackerControl.RunJavaScript(sJavaScript)
It only applies the script to the active document. Please help.
Thank you.
Run Java Script to all open pdf documents
Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
-
- User
- Posts: 518
- Joined: Thu Dec 06, 2007 8:13 pm
-
- Site Admin
- Posts: 1645
- Joined: Thu Mar 27, 2014 6:14 pm
Re: Run Java Script to all open pdf documents
Hi DocuTrack99
JS code gets an active document as 'this'. but it is possible to modify any JS code to work with any document and also there is a way to get all opened documents
I hope this example makes sense. Please note that my knowledge of JS is extremely limited.
I hope this helps!
JS code gets an active document as 'this'. but it is possible to modify any JS code to work with any document and also there is a way to get all opened documents
Code: Select all
Console print n(this path);
Function f(doc)
cov.... Print (doc.path)
for (doc in app. activeDocs)
f(doc);
I hope this helps!
If posting files to this forum, you must archive the files to a ZIP, RAR or 7z file or they will not be uploaded.
Thank you.
Cheers,
Patrick Charest
Tracker Support North America
Thank you.
Cheers,
Patrick Charest
Tracker Support North America