这个程序我实在看不出哪里出错了,请各位大侠帮忙看看,我的代码如下:
<!-- #include file="dbconn.asp" -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>新建网页 3</title>
</head>
<body>
<%
i=1
cph=request.form("cph")
rq1="#"+request.form("rq1")+"#"
rq2="#"+request.form("rq2")+"#"
set rs=server.createobject("ADODB.recordset")
sql="select * from ddfpbzb where ddfpcph like '"&cph&"'and int(fprq) between '"&rq2&"'and '"&rq1&"' "
rs.open sql,conn,1,1
tbs=rs.recordcount
%>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" id="table1" height="42">
<tr bgcolor="#31659C">
<td width="46" height="23"> <div align="center">
<font color="#FFFFFF" size="2"><b>编号</b></font></div></td>
<td width="117" height="23"> <div align="center">
<font color="#FFFFFF" size="2"><b>单位</b></font></div></td>
<td width="136" height="23"> <div align="center">
<font color="#FFFFFF" size="2"><b>车牌号/车型</b></font></div></td>
<td width="105" height="23"> <div align="center">
<font color="#FFFFFF" size="2"><b>司机</b></font></div></td>
<td width="100" height="23"> <div align="center">
<font color="#FFFFFF" size="2"><b>
分配人</b></font></div></td>
<td width="184" height="23"> <div align="center">
<font color="#FFFFFF" size="2"><b>
未分配原因</b></font></div></td>
<td width="93" height="23">
<p align="center"><font color="#FFFFFF" size="2"><b>分配日期</b></font></td>
</tr>
<%do while not rs.eof%>
<tr>
<td width="46" height="20"> <div align="center"><font color="#0000FF"><b><font face="Arial, Helvetica, sans-serif"><%=i%>
<%'=rs("id")%>
</font></b></font></div></td>
<td width="117" height="20"> <div align="center"><%=rs("dw")%></div></td>
<td width="136" height="20"> <div align="center"><%=rs("ddfpcph")%></a></div></td>
<td width="105" height="20"> <div align="center"><%=rs("fpsj")%></div></td>
<td width="100" height="20"> <div align="center"><%=rs("fpr")%> </div></td>
<td width="184" height="20"> <div align="center"><%=rs("wfpyy")%></div></td>
<td width="93" height="20"> <div align="center"><%=rs("fprq")%></td>
</tr>
<%
i=i+1
rs.movenext
loop
%>
<%rs.close
set rs=nothing
%>
</table>
<p align="center"><b><font size="4">本月已使用
台班数为:</font><%=INT(tbs)%></b>
<body>
</p>
</body>
</html>
[此贴子已经被作者于2006-8-24 7:29:40编辑过]