RequiredFeildValidator HELP!!

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi all,
I am using the RequiredFeildValidator on my forms, which works well when i
want to do Adding or Updating on that form, however..
If i go to that form, then try going to a different form, it won't let me
leave because those certain textboxes require info in them, even though i
only want to use those require validators for only the Adding and Updating
buttons...
what should i do????
 
"HOW" are you trying to go to another form?

If you are using an ASP.NET Button, it will render to the client as a SUBMIT
button and therefore require that validations be satisfied.
 
Hai Adam,

I will hep u with a simple solution, which u can try urself.
In ur scenario if u are trying to go to another form, using a command button,
just go to the properties of that command button, just set the property
ClientValidation = false of the command button.


Hope it helps u
Mahi
 
Hi,
Each form on my program has a list of imagebuttons at the top, for the menu,
to navigate from form to form.. then on certain forms i have options where
you can Add, Update, Delete, Find, etc.. info from the database, in which
case i would need the requiredfeild, regularexpression, range validators to
verify that the info is correct before saving it to the database.
The problem is that if you open one of those forms, even if you don't want
to do anything on that form, and try switching to another form by the menu
buttons, it won't let you, because the feilds are required...
I'm off for the weekend now, so won't be able to try anything until monday,
but that "setting the clientValidation = false" on all the menu buttons seems
like it would work and easy enough to do... hope it works!
 
Back
Top