Expand my Community achievements bar.

automatical import of xml by access database

Avatar

Level 3

Hi Guys,


I have another important question. I have LCD 8.0 where I created a pdf form.


An Access database should pull information from the XML and import automatically into the pdf file without human interaction.


The code I am using for importing (which is on the form docready event is: xfa.host.importData("data.xml"); -- but the information is not being automatically filled in, is there a particular syntax for the path? or is there another way to accomplish this?


Thank you for your help in advance!!!


Diana

3 Replies

Avatar

Level 10

Hi Diana,

You have hit a security issue. If you script in the xml file reference (eg import does not require user interaction), then Acrobat sees that something could be happening that the user may not be aware of, therefore it kills it silently.

The only way you can get this to work is if the form is in a trusted environment, like a digitally certified form. The trouble there is distributing and maintaining the certificates across all of the users.

Hope that helps,

Niall

Avatar

Level 3

Hi Niall,

thank you for your answer!!

is there another way how to embedd the form in access with the xml import?  or is there a way how to avoid the certification and being still able to import xml automatically?

The certification is not an option for me.

Thank you!!

Diana

Avatar

Level 10

Hi Diana,

You can set up a data connection between the form and the Access database, using OLEDB. This will work without certification/trusted environment. However it will not work for users with Reader, unless the form has been Reader Enabled using the full LC Reader Extensions ES2 server product.

You can also hardwire XML into the form, but this probably does not suit your needs.

Check out the help file for data connections.

Hope that helps,

Niall