if ClassNum<=50 Then
Response.write "入学年份"
Else
Set enyearRs=conn.execute("select distinct enyear from class order by enyear")
Response.write "<Select name=enyear size=1location.href='RegClass.asp?enyear='+options[this.selectedIndex].value"">"
Response.write "<option value=''>入学年份</option>"
do until enyearRs.eof
Response.write "<option value="&enyearRs(0)
if cstr(enyearRs(0))=Request("enyear") Then Response.write " selected"
Response.write "> "&enyearRs(0)&" </option>"
enyearRs.movenext
loop
Response.write "</Select>"
Set enyearRs=Nothing
End if