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

Preventing submit until after required fields are entered

mark123
Registered: Mar 18 2008
Posts: 10

Hello all -

I'm using a standard button object with a little javascript on the click event to submit a form via email. I also have a validation routine implemented as a function in a script object to make sure the user completes all required fields.

The trouble I'm having is when the button is clicked, the email message always gets created in the email program, the data is attached, and the To: field is filled in with the specified address REGARDLESS of whether the validation routine found any unfulfilled required fields or not.

I know the validation routine is working properly. I just don't know how to prevent the email submission until after the validation verifies that all required fields have been filled out.

Anybody got any ideas on how I can tie the validation routine and the button click together? or is there a nice example that somebody can direct me to?

My Product Information:
LiveCycle Designer, Windows
lkassuba
ExpertTeam
Registered: Jun 28 2007
Posts: 3636
Stephan Cameron has an example script titled [url=http://forms.stefcameron.com/2006/06/26/process-all-fields/]Process All Fields[/url] that might help.

Lori Kassuba is an AUC Expert and Community Manager for AcrobatUsers.com.