
creating a text box errors message for empty text box
This will check a data array before sending it to the server and abort the
submission if there are empty boxes.
<input type=button value="Send" onClick=sender()>
<script language="vbs">
errormessage="All boxes must contain data."
sub sender()
error=false
for n=0 to document.all.formname.data.length-1
if len(document.all.formname.data(n).value)=0 then
error=true
end if
next
if error then
msgbox errormessage
else
document.all.formname.submit
end if
end sub
</script>
--
Dave "Crash" Dummy - A weapon of mass destruction
http://lists.gpick.com