<%
i=1
num=0
typeb="select * from mainclass order by classorder,ID ASC"
set rs_product=conn.execute(typeb)
do while not rs_product.eof
if i=1 and mainclass="" then
line="inline"
else
if rs_product("mainclass")=mainclass then line="inline" else line="none" end if
end if
%>
<%
sql1="select * from proclass where mainclass='"&rs_product("mainclass")&"' order by classorder,ID DESC"
set rs_pro2=conn.execute(sql1)
do while not rs_pro2.eof
%>
<%rs_pro2.movenext
loop
i=i+1
num=num+1
rs_product.movenext
loop
rs_product.close
set rs_product=nothing
%>