Validation fails, form submits anyway

Posted on 2003-03-04
Medium Priority
Last Modified: 2012-06-27
I cannot understand for the life of me why my validation isn't working...

Basically, i'm using a custom validator that calls  a server side function, if it's incorrect it calls args.Value = false;

Yesterday this worked absolutely fine, now i've added one that does much the same sort of thing and now both of them have just stopped working, i can step all the way through my code and it hits the args.value=false statement and then just submits the form anyway!

Why why why???

I should add that i'm assigning any old control the the ControlToValidate property, in the server side event i'm just using my own logic. At the end of the day, in the actual submit routine the Page.IsValid property is false!

Any help would be greatly appreciated
Question by:Rob_Saville
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3

Author Comment

ID: 8063334
Ok i could do if (Page.IsValid)  

but should that just happen automatically???
LVL 23

Accepted Solution

naveenkohli earned 600 total points
ID: 8063687
Form submission has to take place if you have a server side validator. Otherwise how will the code gets executed to figure out of the page is valid or not.
Does the page show error or not, if validator sets the state to false?

Author Comment

ID: 8063723
I've sorted it.

Cheers anyway.

Author Comment

ID: 8112780
A because, i duno really.

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question