怎样写VB程序实现分页功能
sub paged(x)
dim page
response.write " <font size= '2 '> "
response.write( "总记录: ")
response.write(rs.recordcount)
response.write( "条 ")
rowcount=1000
rs.pagesize=rowcount
pages=rs.pagecount
page=cint(request( "page "))
if page= " " or page <1 then page=1
rs.absolutepage=page
if page> 1 then
response.write " <a href= "&(x)& "?id= " & (id)& "&page=1> [首页] </a> "
end if
if page <=1 then
response.write "[首页] "
end if
if page> 1 then
response.write " <a href= "&(x)& "?id= " & (id)& "&page= " & (page-1)& "> [上一页] </a> "
end if
if page <pages then
response.write " <a href= "&(x)& "?id= " & (id)& "&page= " & (page+1)& "> [下一页] </a> "
response.write " <a href= "&(x)& "?id= " & (id)& "&page= " & (pages)& "> [末页] </a> "
end if
if page> =pages then
response.write "[末页] "
end if
end sub
----------------------------
上面如果是写在asp页面里,可以实现分页显示,(其中x参数为要显示的页面文件名)可如果把它们封在DLL文件里,却执行不了,提示为:
-----------------------------
总记录:-1条
Microsoft VBScript 编译器错误 错误 '800a03f6 '
缺少 'End '
/iisHelp/common/500-100.asp,行242
ADODB.Recordset 错误 '800a0cb3 '
当前记录集不支持书签。这可能是提供程序或选定的游标类型的限制。
------------
用VB写DLL文件应该怎么写?
[解决办法]
看下你记录集的打开方式.现在查出的-1条.表示不确定的记录数.所以无法如此分页.
[解决办法]
帮忙顶下