Using Acrobat 8 (Not LC)
I am trying to disable a submit button upon being invoked in order to prevent multiple submissions. I'm handling the submit action and data validation in javascript, so I just need to know what property on the button object to set in order to make it behave as a disabled button. The target of the submission is a web application that can take some time to process before responding to the request, so the liklihood of a double-submission is very high.
Curiously, when I set the Read Only property to true on a button through the UI, it behaves exactly the way I'd want the disabled button to work. However, the field.readonly property always resolves to true through the programmatic interface, as well as the field.access property always resolves to readOnly. It seems like the UI control abstracts some other properties of the object interface, and I can't find anything in the documentation that steers me in the right direction. Please advise how I can set the properties in javascript to make a button behave as if I had set the Read Only checkbox to true through the UI.
Thanks!
http://www.acrobatusers.com/tutorials/2007/js_disabling_fields/
You may also want to consider setting the ReadOnly property on the MouseDown event.
Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script