ASP中,数据库中某字段字数太多,需要分页显示,该如何做?(急)

来源:百度知道 编辑:UC知道 时间:2024/06/09 08:27:23
ASP中,数据库某字段字数太多,一页写不下,需要多页,这种情况如何分页显示?在线求教!谢谢!
有没有简洁一点的代码?

<%
Const maxPagesize=1000 '设置分页字数

Function InsertPageBreak(strText)
Dim strPagebreak,s,ss
Dim i,IsCount,c,iCount,strTemp,Temp_String,Temp_Array
strPagebreak="[hiweb_break]"
s=strText
If Len(s)<maxPagesize Then
InsertPageBreak=s
End If
s=Replace(s, strPagebreak, "")
s=Replace(s, " ", "< >")
s=Replace(s, ">", "<>>")
s=Replace(s, "<", "<<>")
s=Replace(s, """, "<">")
s=Replace(s, "'", "<'>")
If s<>"" and maxPagesize<>0 and InStr(1,s,strPagebreak)=0 then
IsCount=True
Temp_String=""
For i= 1 To Len(s)
c=Mid(s,i,1)
If c="<" Then
IsCount=False
ElseIf c=">" Then
IsCount=True