I have a form which generate the input box dynamically according to the data in the database. When
submitting the form (js function), how can I check if the input box is filled?
if not rs1.EOF then
Response.Write "<TABLE align=center frame=""below"" cellPadding=1 cellSpacing width=600>"
count=0
while not rs1.EOF
count=count+1
Response.Write "<TR border = 0>"& vbCrLf
'min
if rs1.Fields(20)&""<>"" then
Response.Write "<td><input id=lbmin"&count&" name=lbmin"&count&" value="""&rs1.fields(20)&""" ></td>"
else
Response.Write "<td width=80> </td>" & vbCrLf
end if
'ave
if rs1.Fields(21)&""<>"" then
Response.Write "<td><input id=lbave"&count&" name=lbave"&count&" value="""&rs1.fields(21)&""" ></td>"
else
Response.Write "<td width=80> </td>" & vbCrLf
end if
'max
if rs1.Fields(19)&""<>"" then
Response.Write "<td><input id=lbmax"&count&" name=lbmax"&count&" value="""&rs1.fields(19)&""" ></td>"
else
Response.Write "<td width=80> </td>" & vbCrLf
end if
Response.Write "</TR>"& vbCrLf
rs1.MoveNext
wend
Response.Write "</table>"& vbCrLf
Response.Write "<input type=hidden name=count value="&count&">"& vbCrLf
rs1.Close()
%>
submitting the form (js function), how can I check if the input box is filled?
if not rs1.EOF then
Response.Write "<TABLE align=center frame=""below"" cellPadding=1 cellSpacing width=600>"
count=0
while not rs1.EOF
count=count+1
Response.Write "<TR border = 0>"& vbCrLf
'min
if rs1.Fields(20)&""<>"" then
Response.Write "<td><input id=lbmin"&count&" name=lbmin"&count&" value="""&rs1.fields(20)&""" ></td>"
else
Response.Write "<td width=80> </td>" & vbCrLf
end if
'ave
if rs1.Fields(21)&""<>"" then
Response.Write "<td><input id=lbave"&count&" name=lbave"&count&" value="""&rs1.fields(21)&""" ></td>"
else
Response.Write "<td width=80> </td>" & vbCrLf
end if
'max
if rs1.Fields(19)&""<>"" then
Response.Write "<td><input id=lbmax"&count&" name=lbmax"&count&" value="""&rs1.fields(19)&""" ></td>"
else
Response.Write "<td width=80> </td>" & vbCrLf
end if
Response.Write "</TR>"& vbCrLf
rs1.MoveNext
wend
Response.Write "</table>"& vbCrLf
Response.Write "<input type=hidden name=count value="&count&">"& vbCrLf
rs1.Close()
%>