« 一个随机数字验证码程序经典查询排序案例 »

asp自定义函数:得到一个字符串在另一个字符串当中出现几次的函数

Function GetRepeatTimes(TheChar,TheString)
 GetRepeatTimes = (len(TheString)-len(replace(TheString,TheChar,"")))/len(TheChar)
End Function

GetRepeatTimes(TheChar,TheString) 得到一个字符串在另一个字符串当中出现几次的函数

如:
response.write GetRepeatTimes("w","

原创文章如转载,请注明:转载自悠悠博客 [ http://www.ajaxstu.com/ ]

相关文章:

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。