1.执行以下SQL语句
selece count(*) from 表名
2.用这段代码,小生自己写的:)
dim intTotalPage,intCurrentPage
Sub DividePage(objRS,intPageSize,intPageNo)
intTotalPage=int(objRS.recordcount/intPageSize*-1)*-1
intPageNo=CInt(intPageNo)
if intPageNo<1 then
intPageNo=1
elseif intPageNo>intTotalPage then
intPageNo=intTotalPage
end if
objRS.PageSize=intPageSize
objRS.AbsolutePage=intPageNo
intCurrentPage=intPageNo
end sub
set objRS=Server.CreateObject("ADODB.RecordSet")
objRS.open 查询,数据库连接字符串,adOpenStatic,adLockReadOnly
DividePage objRS,10,strPage '10是每页的记录数,strPage是当前要显示的页码
这样,就实现了分页而且intTotalPage就是你想要的。Sub中的代码可以写在include重用。
3.这个问题似乎不是ASP的问题或者说用ASP处理不划算,其实只要把TD的宽度固定以后,再把样式定为"word-break:break-all"就好了。比如: