<%
varState=request.form("drpState"
varCity="Select City"
if varState="" then
varState="Select State"
end if
%>
<form name="form1" method="post" action="samepage.asp">
<select name="drpState" onchange="submit()" size="1">
<%
sql = "SELECT State FROM myTable"
set rs = server.createobject("adodb.recordset"

rs.open sql, conn
%>
<option selected value="<%=varState%>"><%=varState%></option>
<%Do while not rs.eof%>
<option value="<%=rs("State"

%>"><%=rs("State"

%></option>
<%rs.movenext%>
<%loop%>
<%rs.close%>
</select>
</form>
<form name="form2" method="post" action="nextpage.asp">
<input type="hidden" name="varState" value="<%=varState%>">
<select name="drpCity" size="1">
<option selected value="<%=varName%>"><%=varName%></option>
<%if not varState = "Select State" then
set rs = Server.CreateObject("adodb.Recordset"
sql2 = "SELECT City FROM myTable WHERE State = "&varState
rs.open sql2, conn
varCity = rs("City"

rs.close
end if%>
<%Do while not rs.eof%>
<option value="<%=varCity%>"><%=varCity%></option>
<%rs.movenext%>
<%loop%>
<%rs.close%>
</select>
<input type='submit' value='Next>>'>
If you have the patience to wallow through all that I commend you. I changed the concept here to reflect a simple State/City scenario, but the code is the same, albeit abridged. Given this code, the Submit button will not appear, nor anything else after it, until a value for the first(State) dropdown has been specified. As you can see, it pulls the options for both dropdowns from the db.
One thing I dont like about this setup is having to make another trip back to the server to get the 2nd dropdown options. It is not feasible to send all the possible options on the initial load, so I think I am just SOL. I'm starting to think the problem might be with the IF statement in the 2nd form.
I'm interested to hear your thoughts!