Upon pressing the "submit" button of my PDF form, I'd like to do something (set a field to readonly) conditionally on the success of the form validation and submission processes:
if (form.isValid()) {
submitForm(...);
if (form.wasSubmittedSuccessfully()) {
//doSomething();
}
}
I'd like to know if there's an easy way to implement form.isValid()
(i.e. verify that all required fields are non-null and correctly formatted) and form.wasSubmittedSuccessfully()
above.