Copy link to clipboard
Copied
Hi,
I am trying to create a 'Paid' stamp using Acrobat. I have read the 'Dynamics Stamp Secrets' website, but to no avail. Here is what I am going for (when stamp is placed):
< Typable Reference #.
And this is the Java script for the 'Reference':
When I place the stamp, the date appears, but there is no JavaScript Pop-up for me to type my Reference Number. Help would be greatly appricated!
Ok, so never use the Acrobat Stamp tools. I've stated this repeatedly in many of the articles and video tutorials I've created on stamps. These tools destroy all dynamic content and create a completely different static stamp.
And there is no option for creating a dynamic stamp in Acrobat.
After adding fields and scripts to a stamp to make it dynamic, you have to manually copy the stamp file into one of the two Acrobat Stamp folders.
Watch the free videos on stamps here:
https://www.pdfscripting.com/public/All_About_PDF_Stamps.cfm
...Hi,
You must modify the name of the template, something like that: #myStamp=PaidStamp
... and your script: if(event.source.forReal && event.source.stampName == "#myStamp")
Then that's working fine!
You can change myStamp by anything else as long as it's the same in the template and in the script.
@+
Copy link to clipboard
Copied
First, remove the "event.source.source.info" line. This was an example in the article of how to access properties of the document being stampped. It's not necessary for operation.
However, what is necessary is the correct stamp name. Have you verified this?
Here is a video tutorial on how to find the stamp name:
https://www.pdfscripting.com/public/images/Video/FindingStampName.cfm
Copy link to clipboard
Copied
Hello,
Thank you for your response, I have editted as you directed. It still does not work, and I have noticed that when I place the stamp it does not work. The name was actually incorrect, and I have updated it. Here is the updated code.
Copy link to clipboard
Copied
There is nothing wrong with your stamp code. If the stamp name is correct, then the code will work.
Another thing that will cause problems is if there is a copy of this same stamp in a different file or in the other stamp folder. Make sure there is one and only one stamp with this name.
Can you post the stamp file? It would make it easier to debug.
One other thing you can do to debug this is to put this line of code a the top of the stamp script. It will display the stamp name in the console window. This does two things, 1) it shows that the stamp script is running. And it verifies the stamp name you are using in the 'if'
console.println("Stamp:" + event.source.stampName);
Tell us what appears in the console window.
Copy link to clipboard
Copied
Copy link to clipboard
Copied
First, the "console.println" line has a syntax error. JavaScript is case sensitive, so the "s" in "stampName" must be lower case: "event.source.stampName"
Then, the stamp name in the script is incorrect. You must have changed it to "PaidStamp". Which is fine, but it has to be prefixed with a "#" symbol if you want the stamp script to execute when the stamp is placed. This was covered in the Stamp Secrets article.
Fix these and your script is good to go.
Copy link to clipboard
Copied
Hi,
I have done everything as you directed. It isn't working on my side. There was previously different versions of this stamp being created, I deleted them just to be sure it wasn't the issue. I think it might be how I am uploading the stamp.
When I go to test my stamp, I click the floppy disk icon, then use the custom stamps tool to create a dynamic stamp.
I tried to download the PDF on a different computer, and use the stamp tool as normal. It still does not work.
Copy link to clipboard
Copied
Ok, so never use the Acrobat Stamp tools. I've stated this repeatedly in many of the articles and video tutorials I've created on stamps. These tools destroy all dynamic content and create a completely different static stamp.
And there is no option for creating a dynamic stamp in Acrobat.
After adding fields and scripts to a stamp to make it dynamic, you have to manually copy the stamp file into one of the two Acrobat Stamp folders.
Watch the free videos on stamps here:
https://www.pdfscripting.com/public/All_About_PDF_Stamps.cfm
Copy link to clipboard
Copied
Hello Thom,
I have done exactly as you have directed. I read through the entire 'Installing Stamps' page on your website, and followed this video. I have installed the PDF that I sent you to the C:\Program Files (x86)\Adobe\Acrobat DC\Acrobat\plug_ins\Annotations\Stamps folder.
When I login to Acrobat, it does appear as a folder called 'Paid Stamp.xlsx. It has my stamp in it, but when I place it the stamp name doesn't popup in the console when I place the stamp, but rather, the codes runs when I enter the program.
Thanks for your help.
Copy link to clipboard
Copied
Have you looked in the Console Window to see if there are any reported errors? and to see the results of the "console.println" code you put into the stamp script?
You'll find a tutorial on the Console Window here:
https://www.pdfscripting.com/public/Free_Videos.cfm#JSIntro
Copy link to clipboard
Copied
Hi,
You must modify the name of the template, something like that: #myStamp=PaidStamp
... and your script: if(event.source.forReal && event.source.stampName == "#myStamp")
Then that's working fine!
You can change myStamp by anything else as long as it's the same in the template and in the script.
@+