为什么总是出这个呢在对应所需名称或序数的集合中,未找到项目。?????
红色的地方出现这样的错误
<script language="JavaScript">
var subcat = new Array();
<%
i=0
sql1="select * from sheng "
set rs1=conn.execute(sql1)
do while not rs1.eof
sql2="select * from school where bianhao="& rs1("id")&" "
set rs2=conn.execute(sql2)
do while not rs2.eof
%>
subcat[<%=i%>] = new Array("<%= trim(rs1("id"))%>","<%= trim(rs2("bianhao"))%>","<%= trim(rs2("schname"))%>");
<%
rs2.movenext
i=i+1
loop
rs1.movenext
loop
%>
function changelocation(locationid)
{
document.form1.type2.length = 0;
var locationid=locationid;
var i;
document.form1.type2.options[0] = new Option('---请选择---','');
for (i=0;i < subcat.length; i++)
{
if (subcat[i][0] == locationid)
{
document.form1.type2.options[document.form1.type2.length] = new Option(subcat[i][2], subcat[i][1]);
}
}
}
</script>
<FORM action=### name=form1 id="form1">
<BR>
地区:
<select name="type" onChange="changelocation(this.value)">
<option value="0">--请选择--</option>
<%
lb2=request("lb")
set list = server.createobject("adodb.recordset")
list.open "select * from sheng",conn,3,1
do while not list.eof
%>
<option value="<%=list("id")%>"><%=list("shengfen")%></option>
<%
list.movenext
loop
%>
</select>
高校:
<select name="type2" id="type2" >
<option value="">---请选择---</option>
</select>