Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

DocClose event runs twice after extending with user rights


Level 2

I have created a form with several fields. To check if the fields are filled, I have placed several checks if the DocClose event. This creates a messagebox containing text of the missing fields. This will only popup when the pdf is closed. See below for a part of the Java-script.


var errmsg = ""

if (Form.Page1.CompanyName.rawValue == null)

{errmsg = errmsg + "CompanyName is not filled in";}

if (Form.Page1.CompanyStreet.rawValue == null)

{errmsg = errmsg + "\n";

errmsg = errmsg + "CompanyStreet is not filled in";}

if (errmsg !== "")

{ (errmsg, "Please note!",1,0);}




This works just fine in Adobe Acrobat and in Adobe Reader. However,the user needs to be able to save a local copy. So, I use Adobe Acrobat 9 Standard to "Extend Forms Fill-In & Save in Adobe Reader". After this change, when this PDF is opened in the Reader or in Acrobat, the messagebox runs twice! The first time as it should, but the second time, it

I also noticed that the Script language of this part has changed from Java to mixed.

Thanks for any help!


2 Replies


Level 10

Can you share your form so I can have a look and see what is happening? You can send it to

Please include a description of the issue as there is no corelation from that email back to this forum.



Level 1

Dear all,

I have the same problem, do you have any solution for this?

Best regards