Order within the Validation Summary
ASP.NET
Thread Starter: mike55
Started:
Replies: 0

Ireland .NET Developer Alliance :: Forums » Technologies » ASP.NET » Order within the Validation Summary
« Previous Thread Next Thread »
   17 Oct 2005, 2:05
mike55 is not online. Last active: 21/12/2005 09:28:10 mike55

Top 10 Posts
Joined on 01-20-2005
Posts 40
Order within the Validation Summary
Hi all,

Have a number of required field validators on my web form. The EnableClientScript is set to False. I also have validation summary control on my page.

When I hit the save button, a method called ExecuteValidation is called. This method firstly calls the individual validators.
Code:
 me.requiredFieldValidator1.validate me.requiredFieldValidator2.validate me.requiredFieldValidator3.validate

The method then proceeds to check if the validator is correct or not.
Code:
 if me.requiredFieldValidator1.isvalid = false then ExecuteValidation = false end if if me.requiredFieldValidator2.isvalid = false then ExecuteValidation = false end if if me.requiredFieldValidator3.isvalid = false then ExecuteValidation = false end if

The problem that I am having is that I want the validation statements for requiredFieldValidator 1, 2, and 3 to appear in the order 1, 2, 3. However I practice the order is constantly changing.

Any suggestions on how to control the order?

Mike55.
  
  Page 1 of 1 (1 items)
Ireland .NET Developer Alliance :: Forums » Technologies » ASP.NET » Order within the Validation Summary

Powered by Community Server :: Forums