Skip to main content
scottp51589877
Participant
October 17, 2017
Answered

acrobat signature preventing app.mailMsg() from executing

  • October 17, 2017
  • 2 replies
  • 975 views

I have a PDF form that has a submit button that sends a notification email using the javascript app.mailMsg() function. I need to use app.mailMsg() as the form is auto-saved to a company server as it's filled out and I just need to send a notification email using one of the form variables (the doc. number). I do not need to send the form.

The form also uses a digital signature field to track who in the company is submitting forms. My problem is, if someone signs the document, the app.mailMsg() call ceases to work and generates the following error:

NotAllowedError: Security settings prevent access to this property or method. Doc.subject:2:Field SUBMIT:Mouse Up

I've managed to track the problem to the digital signature. At any point, before signing the document, if the submit button is clicked, it generates the appropriate email. Once the document is signed, security measures prevent the submit button from working. Is there a way to fix/workaround this issue?

This topic has been closed for replies.
Correct answer try67

My guess is they've created a variable called "subject", which is conflicting with the internal property of the Document object with that name, so moving the code won't solve it. Renaming the variable to something else will.

2 replies

Joel Geraci
Community Expert
Community Expert
October 17, 2017

You can move your code from the submit button to the Signature field so that it executes when the document gets signed.

try67
Community Expert
try67Community ExpertCorrect answer
Community Expert
October 17, 2017

My guess is they've created a variable called "subject", which is conflicting with the internal property of the Document object with that name, so moving the code won't solve it. Renaming the variable to something else will.

scottp51589877
Participant
October 17, 2017

thanks try67! renamed the subject variable and it's working great!

Too bad I just found out the method isn't supported in reader which is what 90% of our employees will use...

try67
Community Expert
Community Expert
October 17, 2017

Can you post your code?

On Tue, Oct 17, 2017 at 8:46 PM, scottp51589877 <forums_noreply@adobe.com>