您的当前位置:教程首页 --> ASP教程 --> ASP技巧 --> 分行模块,自动识别英文和型号数[推荐精华]

分行模块,自动识别英文和型号数[推荐精华]

发布时间:2009/06/24  来源:网络  点击次数:68次
Function cuttextlen(intext, lens)
    If Len(intext) <= lens Then
        cuttextlen = intext
    Else
        tmptext = intext
        GetTexts = ""
        Do While Not Len(tmptext) <= lens
        
       GetTexts = GetTexts + Left(tmptext, lens)
       tmptext = Right(tmptext, Len(tmptext) - lens)
       Do While (Asc(Left(tmptext, 1)) >= 65 And Asc(Left(tmptext, 1)) <= 90) Or (Asc(Left(tmptext, 1)) >= 97 And Asc(Left(tmptext, 1)) <= 122) Or (Asc(Left(tmptext, 1)) >= 45 And Asc(Left(tmptext, 1)) <= 57)
           GetTexts = GetTexts + Left(tmptext, 1)
           tmptext = Right(tmptext, Len(tmptext) - 1)
           'If Len(tmptext) <= lens Then Exit Do
       Loop
        GetTexts = GetTexts & "<br>"
        Loop
        cuttextlen = GetTexts & tmptext
    End If
End Function
具体例子位置还是WWW.HIFI-CHINA.COM

站长QQ:28212441

太仓交友 张家界会议网 齐齐商务  直流电机维修 

Copyright © 2007 www.herecn.com! company. All rights reserved.

苏ICP备09011162号