JohannIcon
Programmer
Dear All,
I have an input form where the user must enter his name, surname, e-mail address and choose from three topics, namely Conference, Leisure or Corporate. He can choose as many as he like, however, he has to choose one before submitting the form.
How can I do the validation on these checkboxes?
I came up with this code:-
If request.form("Conference"
= "" then
er = 1
End IF
if er <> 1 then
If request.form("Leisure"
= "" then
er = 1
End IF
end if
if er <> 1 then
If request.form("Corporate"
= "" then
er = 1
End IF
end if
If er = 1 then
message = "You have to choose at least one check box"
end if
However, how can I stop the form from being submitted?
Thanks for your help and time
I have an input form where the user must enter his name, surname, e-mail address and choose from three topics, namely Conference, Leisure or Corporate. He can choose as many as he like, however, he has to choose one before submitting the form.
How can I do the validation on these checkboxes?
I came up with this code:-
If request.form("Conference"
er = 1
End IF
if er <> 1 then
If request.form("Leisure"
er = 1
End IF
end if
if er <> 1 then
If request.form("Corporate"
er = 1
End IF
end if
If er = 1 then
message = "You have to choose at least one check box"
end if
However, how can I stop the form from being submitted?
Thanks for your help and time