We have a document with a "validate" button.
Pressing this button performs several validations and the result will be : "validated" or "not validated"
The result is being displayed to the end user as a document status (with it's own color).
Once the new "status" = "validated", the status should be automatically reset to "not validated" when the user makes 1 of more change to the document.
Is there an easy way to do this?
Is there a sort of document status you can fetch?
I'd say it is possible. You could propogate a enter event and an exit event and compare the values of the field before and after. If there is a change in values then change the status.
You would set up a script object with an enter function first and then an exit function.
Are you up for that?
Thanks for your reply.
I understand what you are saying but I am not familiar with propogating events.
Could you provide some more information? Or maybe a small example?
I am sure that John Brinkman discusses propogating events on his blog. http://blogs.adobe.com/formfeed/
I can't do up a sample at the moment, but will try and get something done over the next day or two.
Niall's way wil lwork but this one might be easier.
Acrobat has a "dirty" flag that gets set each time a change is made to the doc. This is what tells Acrobat that you need to do a save when you quit. You can test this flag yourself. To access it use:
This will return true if a change has been made and false if no changes have been made. Note that if someone enters data into a field and then deletes that data the flag will still be true as a change was deemed to have been made.