Ask a Question related to ASP.NET General, Design and Development.
-
SStory #1
requiredvalidator for checkbox
Is there no way to require a checkbox to be checked in ASP.NET?
The requiredvalidator control doesn't work for it--should I make a
server--roundtrip for that and check during the btn_click event? Is there
another way?
Thanks,
Shane
SStory Guest
-
[PHP] Q: How to get the value of a checkbox of which name without '[]'?
> Consider the following form in a HTML file: -
checkbox
I know there is a way to update records with a checkbox. Is there a way to update this records (with different value)by unchecking the checkbox? -
Howto bind CheckBox to the datagrid/ Then update the database field when the checkbox is clicked.
I am trying to update the database field when the checkbox is clicked. I am trying to modified the following solution but.. got stuck on the... -
Q: How to get the value of a checkbox of which name without '[]'?
Consider the following form in a HTML file: .... <input type=checkbox name="box" value=1> <input type=checkbox name="box" value=2> <input... -
Checkbox - How can i get the value ?
Hi, I have an application asp.net using datalist with checkbox for each datalist item... I want to get the value of the item that is checked but... -
Marina #2
Re: requiredvalidator for checkbox
I've used a CustomValidator, and wrote some client side javascript to do
this type of check. That way you will avoid the roundtrip.
You could just as easily forgo the validators, and just write your own
routine for this, but I had some other validators on the page that were
being displayed in a validation summary, so it was more convenient.
"SStory >" <Shane_Story@online.msn.com <remove the 'online.' to send me
mail> wrote in message news:euuXhosVDHA.2040@TK2MSFTNGP11.phx.gbl...> Is there no way to require a checkbox to be checked in ASP.NET?
> The requiredvalidator control doesn't work for it--should I make a
> server--roundtrip for that and check during the btn_click event? Is there
> another way?
>
> Thanks,
> Shane
>
>
Marina Guest
-
Marina #3
Re: requiredvalidator for checkbox
custom validators do not require you to set that property. You can leave it
blank. Be sure to define a javascript function, and list it in the property
that speficies which client side function to run for the validation.
"SStory >" <Shane_Story@online.msn.com <remove the 'online.' to send me
mail> wrote in message news:ew$9nrsVDHA.2104@TK2MSFTNGP10.phx.gbl...> Yeah I know, but when I click ControlToValidate for, the checkbox controls
> don't list????
>
> How did you handle that?
>
> "Marina" <zlatkinam@nospam.hotmail.com> wrote in message
> news:errZRqsVDHA.652@tk2msftngp13.phx.gbl...> there> > I've used a CustomValidator, and wrote some client side javascript to do
> > this type of check. That way you will avoid the roundtrip.
> >
> > You could just as easily forgo the validators, and just write your own
> > routine for this, but I had some other validators on the page that were
> > being displayed in a validation summary, so it was more convenient.
> >
> > "SStory >" <Shane_Story@online.msn.com <remove the 'online.' to send me
> > mail> wrote in message news:euuXhosVDHA.2040@TK2MSFTNGP11.phx.gbl...> > > Is there no way to require a checkbox to be checked in ASP.NET?
> > > The requiredvalidator control doesn't work for it--should I make a
> > > server--roundtrip for that and check during the btn_click event? Is>> >> > > another way?
> > >
> > > Thanks,
> > > Shane
> > >
> > >
> >
>
Marina Guest
-
SStory #4
Re: requiredvalidator for checkbox
Muchas gracias! :)
I am very glad that someone answered that question for me.
Shane
"Marina" <zlatkinam@nospam.hotmail.com> wrote in message
news:OHCzSusVDHA.2016@TK2MSFTNGP09.phx.gbl...it> custom validators do not require you to set that property. You can leaveproperty> blank. Be sure to define a javascript function, and list it in thecontrols> that speficies which client side function to run for the validation.
>
> "SStory >" <Shane_Story@online.msn.com <remove the 'online.' to send me
> mail> wrote in message news:ew$9nrsVDHA.2104@TK2MSFTNGP10.phx.gbl...> > Yeah I know, but when I click ControlToValidate for, the checkboxdo> > don't list????
> >
> > How did you handle that?
> >
> > "Marina" <zlatkinam@nospam.hotmail.com> wrote in message
> > news:errZRqsVDHA.652@tk2msftngp13.phx.gbl...> > > I've used a CustomValidator, and wrote some client side javascript towere> > > this type of check. That way you will avoid the roundtrip.
> > >
> > > You could just as easily forgo the validators, and just write your own
> > > routine for this, but I had some other validators on the page thatme> > > being displayed in a validation summary, so it was more convenient.
> > >
> > > "SStory >" <Shane_Story@online.msn.com <remove the 'online.' to send>> > there> > > mail> wrote in message news:euuXhosVDHA.2040@TK2MSFTNGP11.phx.gbl...
> > > > Is there no way to require a checkbox to be checked in ASP.NET?
> > > > The requiredvalidator control doesn't work for it--should I make a
> > > > server--roundtrip for that and check during the btn_click event? Is> >> > > > another way?
> > > >
> > > > Thanks,
> > > > Shane
> > > >
> > > >
> > >
> > >
> >
>
SStory Guest



Reply With Quote

