These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Trusted Folder Level Scripts

csearl
Registered: Aug 10 2006
Posts: 28

Hi Thom,
Thank for the quick reply.
 
My previous question failed to mention that my Trusted scripts were folder level scripts. They are located in C:\Program Files\Adobe\Acrobat 8.0\Acrobat\Javascripts. Only Administrator should be able to add or update scripts there.
 
The scripts execute flawlessly if run from a button or event in the PDF, so I know the script is valid.
 
I can get my VB application to p execute the script, but it I receive an error message (see previous question for the extact message).
 
If my script is trusted and my PDF is certified, then what else needs to happen for it to run the trusted script?
 
Thanks again.

My Product Information:
Acrobat Pro 8, Windows
thomp
Expert
Registered: Feb 15 2006
Posts: 4411
It looks like you've done almost everything correctly. First, you don't need the "trustedPropagator" function, you only need the trusted function, so you can move the export function into the main trustedFunction. The PDF Shouldn't need to be certified either. But regardless, it should work the way you've done it, especially since it works from a button on a PDF. This is the test I use to make sure a script will work from the IAC.

Have you tried this with Acrobat 7.0? Adobe tightened security on Acrobat 8, and they did it in some odd places. It's possible that this is one of them.

So I've got another suggestion for you. Collect the export data as a string, pass it back to your VB script, and have VB write it out to a file. Like this:

return xfa.data.saveXML();


that's all you need and I don't think it even needs a trustedFunction.

Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script