<% Dim ClsValue ClsValue=Reuqest("clsValue"); IF ClsValue<>"" Then '这里写获取ClsValue(下拉列表框选择值)后的代码 End IF %>
sjzfls 发布留言 2008-10-28 00:07
非常感谢 yms123 斑竹的帮助~~~[em10] 我就是想要这样的代码写法!~
不过有些问题: 我这样的改的
........ ........ 前面都是按斑竹说的代码,就下面 <% IF ClsValue<>"" Then
'这里写获取ClsValue(下拉列表框选择值)后的代码 End IF %>[/bo]
改成 <% IF ClsValue<>"" Then <% exec="select top 5 * from news order by id desc " set rs=server.createobject("adodb.recordset") rs.open exec,conn,1,1 %> <% if rs.eof and rs.bof then response.write("暂时没有数据") else do while not rs.eof %>
<%response.write(Setlen(rs("news_head"),18))%>
<% rs.movenext loop end if %>'这里写获取ClsValue(下拉列表框选择值)后的代码 End IF %>[/bo]
后提示错误阿
提示如下:[/bo] ClsValue=Reuqest("clsValue"); <% IF ClsValue<>"" Then <% exec="select top 5 * from news order by id desc "[0]Script error detected at line 1150,col[35]. Source line: ClsValue=Reuqest("clsValue"); Description: 语句未结束