一个ASP问题。急~!!!在线等待。谁能帮帮我啊?

FrostG 2004-02-02 06:52:23
Microsoft VBScript 编译器错误 错误 '800a03f6'

缺少 'End'

/iisHelp/common/500-100.asp,行242

ADODB.Recordset 错误 '800a0cb3'

Current Recordset does not support bookmarks. This may be a limitation of the provider or of the selected cursortype.

/work/maingsl.asp,行53
...全文
29 9 打赏 收藏 转发到动态 举报
写回复
用AI写文章
9 条回复
切换为时间正序
请发表友善的回复…
发表回复
TrueAndFalse 2004-02-02
  • 打赏
  • 举报
回复
恭喜..呵呵,解决了就好
FrostG 2004-02-02
  • 打赏
  • 举报
回复
回复人: ygghost(刘华强) ( ) 信誉:100 2004-02-02 19:09:00 得分:0

objPagingRS.open strSQL,conn,3,1
这样看看



OK 问题解决了
谢谢大家~!!!
snower01 2004-02-02
  • 打赏
  • 举报
回复
检查一下if语句,缺少一个end if。
ygghost 2004-02-02
  • 打赏
  • 举报
回复
objPagingRS.open strSQL,conn,3,1
这样看看
FrostG 2004-02-02
  • 打赏
  • 举报
回复
错误出在
Rs_tmp.AbsolutePage = PageNo
这一行
FrostG 2004-02-02
  • 打赏
  • 举报
回复
我是菜鸟~! 拜托了~!!!
FrostG 2004-02-02
  • 打赏
  • 举报
回复
<html>
<body>
<head>
<script language="JavaScript"><!--
function openwindows(name) {
thishost = self.location.href
thispath = thishost.substring(0,thishost.lastIndexOf('/')+1)
photosite = thispath+name
photowindow = window.open('',"Blah","resizable=1,location=0,scrollbars=1,width=536,height=427")
this.photowindow.location = photosite

}
// --></script>
</head>
<form>
<%
response.write "<link rel='stylesheet' type='text/css' href='style.css'>"

'Dim RowCount 每页显示的记录数;

Dim fileName,postion
Dim PageNo '当前显示的是第几页
Dim TotalPage '页面总数
Dim iPageCurrent '显示的当前页面
Dim strSQL '执行的SQL语句
Dim objPagingRS
Dim RecordCount '总记录条数

set conn=server.createobject("ADODB.CONNECTION")
conn="Provider=SQLOLEDB;Data Source=192.168.0.3;uid=cbr;pwd=cbrtest"
strSQL="select * from data1"

set objPagingRS=server.CreateObject("ADODB.RecordSet")
objPagingRS.open strSQL,conn,1,3

'RowCount=15

iPageCount = objPagingRS.pageCount


Sub TurnPage(ByRef Rs_tmp,PageSize) 'Rs_tmp 记录集 PageSize 每页显示的记录条数;
Rs_tmp.PageSize = PageSize
RecordCount = Rs_tmp.RecordCount
TotalPage = INT(RecordCount / PageSize * -1)*-1
PageNo = Request.QueryString ("PageNo")
'直接输入页数跳转;
If Request.Form("PageNo")<>"" Then PageNo = Request.Form("PageNo")
'如果没有选择第几页,则默认显示第一页;
If PageNo = "" then PageNo = 1
If RecordCount <> 0 then
'response.write pageno
'response.end()
Rs_tmp.AbsolutePage = PageNo
End If
'获取当前文件名,使得每次翻页都在当前页面进行;
fileName = Request.ServerVariables("script_name")
postion = InstrRev(fileName,"/")+1
'取得当前的文件名称,使翻页的链接指向当前文件;
fileName = Mid(fileName,postion)



%>
<%End Sub%>

<%
Dim RowCount
RowCount = 20 '每页显示的记录条数
Call TurnPage(objPagingRS,RowCount)
'If Not objPagingRS.eof then
'Do while Not objPagingRS.eof and RowCount>0
%>

<table width="100%" border="1">
<tr>
<td>项目编号</td>
<td>项目分类</td>
<td>项目名称</td>
<td>项目类型</td>
<td>立项时间</td>
<td>负责人</td>
</tr>
<%

dim p1

objPagingRS.movefirst

'while not objPagingRS.eof
If Not objPagingRS.eof then
Do while Not rt.eof and RowCount>0
%>
<tr>
<td><a href="c_file.asp?name1=<%=objPagingRS("C_Num")%>"><%response.write trim((objPagingRS("C_Num"))) %></td>
<td><%response.write trim((objPagingRS("C_Fl"))) %></td>
<%
'p1=trim(objPagingRS("c_Name"))&trim(objPagingRS("c_Fl"))

%>

<td><a href="file/file_upload.asp?c_name1=<%=objPagingRS("c_Num")%>&c_name2=<%=objPagingRS("c_Fl")%>&c_name3=<%=objPagingRS("c_Name")%>"><%=trim((objPagingRS("C_Name"))) %></td>
<td><%response.write trim((objPagingRS("C_Type"))) %></td>
<td><%response.write trim((objPagingRS("C_Time"))) %></td>
<td><%response.write trim((objPagingRS("C_Man"))) %></td>
</tr>
<%
RowCount = RowCount - 1
objPagingRS.movenext
loop
end if

%>
</table>

<table width="753" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#CCCCCC">
<tr>
<td width="17"> </td>
<td width="456" height="25" >总页数:<font color=#ff3333> <%=TotalPage%> </font>页 当前第<font color=#ff3333> <%=PageNo%></font> 页</td>
<td width="275" align="center">
<%If RecordCount = 0 or TotalPage = 1 Then
Response.Write "首页|前页|后页|末页"
Else%>
<a href="<%=fileName%>?PageNo=1">首页|</a>
<%If PageNo - 1 = 0 Then
Response.Write "前页|"
Else%>
<a href="<%=fileName%>?PageNo=<%=PageNo-1%>">前页|</a>
<%End If

If PageNo+1 > TotalPage Then
Response.Write "后页|"
Else%>
<a href="<%=fileName%>?PageNo=<%=PageNo+1%>">后页|</a>
<%End If%>
<a href="<%=fileName%>?PageNo=<%=TotalPage%>">末页</a>
<%End If%></td>
<td width="5"> </td>
</tr>
</table>
</form>
</body>
</html>
ygghost 2004-02-02
  • 打赏
  • 举报
回复
/work/maingsl.asp,行53
---------贴出来看看
luluso 2004-02-02
  • 打赏
  • 举报
回复
rs.open sql,conn,1,1
rs.open sql,conn,1,3

28,391

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧