最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
asp取得字符长度函数
时间:2022-07-02 22:43:12 编辑:袖梨 来源:一聚教程网
function gotTopic(str,strlen)
if str="" then
gotTopic=""
exit function
end if
dim l,t,c, i
str=replace(replace(replace(replace(str," "," "),""",chr(34)),">",">"),"<","<")
l=len(str)
t=0
for i=1 to l
c=Abs(Asc(Mid(str,i,1)))
if c>255 then
t=t+2
else
t=t+1
end if
if t>=strlen then
gotTopic=left(str,i) & "…"
exit for
else
gotTopic=str
end if
next
gotTopic=replace(replace(replace(replace(gotTopic," "," "),chr(34),"""),">",">"),"<","<")
end function
相关文章
- 无期迷途局长长阶怎么样 无期迷途局长装束长阶介绍 11-25
- 重返未来1999J什么时候up 重返未来晴日决胜局卡池活动介绍 11-25
- 时空中的绘旅人罗夏妄语怎么样 11-25
- 重返未来1999J什么时候up 11-25
- 无期迷途哈梅尔依偎涟漪怎么样 四星装束哈梅尔依偎涟漪介绍 11-25
- 剑与远征折翼苍空攻略 剑与远征奇境探险折翼苍空怎么过 11-25