手机
当前位置:查字典教程网 >编程开发 >ASP教程 >asp 中英文字符长度检测判断函数
asp 中英文字符长度检测判断函数
摘要:functionstrLength(str)ONERRORRESUMENEXTdimWINNT_CHINESEWINNT_CHINESE=(...

function strLength(str)
ON ERROR RESUME NEXT
dim WINNT_CHINESE
WINNT_CHINESE = (len("论坛")=2)
if WINNT_CHINESE then
dim l,t,c
dim i
l=len(str)
t=l
for i=1 to l
c=asc(mid(str,i,1))
if c<0 then c=c+65536
if c>255 then
t=t+1
End if
next
strLength=t
else
strLength=len(str)
End if
if err.number<>0 then err.clear
End function

【asp 中英文字符长度检测判断函数】相关文章:

ASP 非法字符过滤函数

asp 获取地址栏参数代码

asp 删除图片与文件函数

计算两个时间之差的函数

asp 日期格式化函数

ASP FSO文件处理函数大全

asp之字符串操作函数

字符批量替换程序asp服务器版

遍历目录以及目录下文件的函数

多字段模糊搜索的函数

精品推荐
分类导航