Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Making a user check a check box

Status
Not open for further replies.

n0795

Programmer
Jul 30, 2001
136
US
I want to make a user check a check box before they submit a form, if they do all is well, if they dont it gives them a message or directs them to a page
 
Use the on exit event of the form.

If chkYouCheck.value <> -1 then
DoSomething
cancel = true
Else
Cancel = false
 
Correct me if I am wrong, but IMHO DBGuy's answer is applicable only to VB.


Don't have a submit button; Instead have an ordinary button and call the submit() function, if everything is alright..

If the chkBox value is a number, onclick of that button, then use isNaN() function in Javascript/ or IsNull/IsNumeric in VBScript.

HTH Thank you...
RR

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top