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

[AEM Gems Webinar] Accelerating Experience Manager as a Cloud Service development with Rapid Development Environments

Internal error when using doc.importXFAData


Level 1

I have a XFA form created in LiveCycle (not by me)... and I've created a custom menu item that exports a .xml file upon clicking.

I've created a second menu item that imports a specific xml file into the report, however it is returning "An Internal error occurred"  BUT it also properly imports the data too.

There are 3 folder level trusted javascript functions being used in order to do this. I have 2 specific questions:

1) Can you spot why I'm getting an error using the code below (import.js)?

2) Is it possible for Acrobat to "wait for" an xml file to be created on the desktop before importing automatically. Ideally I'd only create one menu item which performs two functions: exports the xml file and then WAITS until a specifically-named .xml file appears in a given directory, before automatically importing it into the form.

Thanks a lot.


1) menu.js (creates two menu items, Export and Import).

app.addMenuItem({cName:"Export", cParent:"Edit", cExec:""})

app.addMenuItem({cName:"Import", cParent:"Edit", cExec:""})

2) export.js (working without errors)

var myTrustFunct = app.trustedFunction(function(doc)





   bCopy: true,

          bPromptToOverwrite: false,






3) import.js (causing error despite successful import)

var myTrustFunctTwo = app.trustedFunction(function(doc)








1 Reply


Level 1

Bump.... The issue only occurs on my Windows 7 64-bit machine running Acrobat Pro 11.0. It runs fine on XP with Acrobat Standard 11.0.

What could be the issue?