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

add attachment after form is signed - NotAllowedError


Level 1

Hi All!

We have PDF form with digital signature.

The form is developed in LiveCycle designer 8.2. The form is dynamic.

One very important User wants to be able to add an attachment after she signs the form :

- immediately (in the same Adobe session)


- sometimes later.

She was able to do that before Adobe Pro XI was installed on her PC (I think she had Adobe Pro 8 before).

Now after she signs the form - the standard "Add" icon in Attachments is grayed out.

It looks like there is a workaround to overwrite the enhanced security implemented by Adobe by using JavaScript API “importDataObject”.

I implemented the solution recommended by Adobe experts (see the links in the end of this post).

But it doesn't work.

I am receiving an error "NotAllowedError: Security settings prevent access to this property or method".

1. According to the links - API “importDataObject” can be executed only by another API “app.trustedFunction”.

2. “importDataObject” can only be executed in Privileged context.

3. Privileged context is Folder Level.

What I did:

1. Created config.js in C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\Javascripts:

   var importMyAttachment = app.trustedFunction(function(oDoc, sFile){
      var rtn = oDoc.importDataObject(sFile);


2. In LiveCycle designer created custom button "Add Attachment"

     On click event created JS code.

The code is saying: call API importDataObject from privileged context in folder level:

var myDoc =;
if(typeof(importMyAttachment) == "function"){

var sFile = "myLittleFile";
console.println("Missing Attach Fucntion");

3. Opened the form in Adobe pro XI.

- signed the form.

- clicked my custom button "Add Attachment".

- received error "NotAllowedError: Security settings prevent access to this property or method."

From JS debugger  - I can clearly see that API importDataObject is called by trusted function in folder level:

folder level.jpg

Here are the links I used for the workaround: wwhelp.htm?context=Acrobat9_HTMLHelp&file=JS_API_AcroJS.88.323.html wwhelp.htm?context=Acrobat9_HTMLHelp&file=JS_API_AcroJS.88.323.html

How to Add attachment after the form is signed?

Your input is greatly appreciated.



0 Replies