Highlighted

Validation running twice

Thomas_McConnac

09-12-2008

Hi all,



To set my problem into context, this is the order of events:



-Choose an option, makes field visible

-Fill field in with data

-Press button which:

-Checks which fields should be mandatory, and makes them so

-Runs execValidate()

-Hides parent subform and makes next parent subform visible

-Go back to previous parent subform

-Delete data from field

-Press button which:

-Checks which fields should be mandatory, and makes them so

-Runs execValidate()

-Doesn't change subform



However, the second time around it is running the validation script twice and displaying my message "The field XXX is mandatory and has not been completed" twice.



Any ideas why this is hapenning?



Many thanks,



Tom

Replies

Highlighted

pguerett

09-12-2008

Are you invoking the execValidate on the individual field or on the subform that contains the field or on the entire form? These types of things are difficult unless we can see the context that things are running in. If you post your form to livecycle8@gmail.com I can have a look and see if there is something I can see that would be causing this.
Highlighted

Thomas_McConnac

09-12-2008

I'm invoking it on the subform that is visible, so one step down from the entire form.



Will send it in about 5 mins.



You're still a star as always Paul 🙂



Tom