Forum for the PDF-XChange Editor - Free and Licensed Versions
Moderators: TrackerSupp-Daniel , Tracker Support , Paul - Tracker Supp , Vasyl-Tracker Dev Team , Chris - Tracker Supp , Sean - Tracker , Ivan - Tracker Software , Tracker Supp-Stefan
dawid_111
User
Posts: 2 Joined: Tue Nov 19, 2019 12:33 pm
Post
by dawid_111 » Tue Nov 19, 2019 12:48 pm
Hello,
I made a dynamic stamp to show the file name. Unfortunately, the stamp shows the name of the file with dynamic stamps, something like:
3a723805-de1b-412c-a5901f781714cb2b.pdf
It should show something like this:
file11.pdf
My dynamic stamp:
Code: Select all
var nazwa = new String;
nazwa = documentFileName.replace(/.pdf/,"");
event.value = util.printf (nazwa);
Tracker Supp-Stefan
Site Admin
Posts: 17949 Joined: Mon Jan 12, 2009 8:07 am
Location: London
Post
by Tracker Supp-Stefan » Tue Nov 19, 2019 2:28 pm
Hello David,
Yes - if you take the name like this - it will be the value of the file in which the stamp itself resides.
Please try e.g.:
Code: Select all
event.value = event.source.source.documentFileName.replace(/.pdf/,"");
Cheers,
Stefan
dawid_111
User
Posts: 2 Joined: Tue Nov 19, 2019 12:33 pm
Post
by dawid_111 » Tue Nov 19, 2019 6:19 pm
Problem solved. Thanks
Paul - Tracker Supp
Site Admin
Posts: 6901 Joined: Wed Mar 25, 2009 10:37 pm
Location: Chemainus, Canada
Post
by Paul - Tracker Supp » Tue Nov 19, 2019 8:32 pm
Best regards
Paul O'Rorke
Tracker Support North America
http://www.tracker-software.com