手机
当前位置:查字典教程网 >编程开发 >ASP教程 >asp 取得中文句子头一个字的大写拼音字母的函数
asp 取得中文句子头一个字的大写拼音字母的函数
摘要:取得中文句子头一个字的大写拼音字母=45217Andtmp=45253Andtmp=45761Andtmp=46318Andtmp=4682...

取得中文句子头一个字的大写拼音字母

<%

'******************************

'函数:getpychar(char)

'参数:char,任意中文字符或句子

'作者:阿里西西

'日期:2007/7/15

'描述:取得中文句子头一个字的大写拼音字母

'示例:getpychar("欢迎访问阿里西西")

'******************************

Functiongetpychar(char)

Dimtmp

tmp=65536+Asc(char)

If(tmp>=45217Andtmp<=45252)Then

getpychar="A"

ElseIF(tmp>=45253Andtmp<=45760)Then

getpychar="B"

ElseIF(tmp>=45761Andtmp<=46317)Then

getpychar="C"

ElseIF(tmp>=46318Andtmp<=46825)Then

getpychar="D"

ElseIF(tmp>=46826Andtmp<=47009)Then

getpychar="E"

ElseIF(tmp>=47010Andtmp<=47296)Then

getpychar="F"

ElseIF(tmp>=47297Andtmp<=47613)Then

getpychar="G"

ElseIF(tmp>=47614Andtmp<=48118)Then

getpychar="H"

ElseIF(tmp>=48119Andtmp<=49061)Then

getpychar="J"

ElseIF(tmp>=49062Andtmp<=49323)Then

getpychar="K"

ElseIF(tmp>=49324Andtmp<=49895)Then

getpychar="L"

ElseIF(tmp>=49896Andtmp<=50370)Then

getpychar="M"

ElseIF(tmp>=50371Andtmp<=50613)Then

getpychar="N"

ElseIF(tmp>=50614Andtmp<=50621)Then

getpychar="O"

ElseIF(tmp>=50622Andtmp<=50905)Then

getpychar="P"

ElseIF(tmp>=50906Andtmp<=51386)Then

getpychar="Q"

ElseIF(tmp>=51387Andtmp<=51445)Then

getpychar="R"

ElseIF(tmp>=51446Andtmp<=52217)Then

getpychar="S"

ElseIF(tmp>=52218Andtmp<=52697)Then

getpychar="T"

ElseIF(tmp>=52698Andtmp<=52979)Then

getpychar="W"

ElseIF(tmp>=52980Andtmp<=53640)Then

getpychar="X"

ElseIF(tmp>=53689Andtmp<=54480)Then

getpychar="Y"

ElseIF(tmp>=54481Andtmp<=62289)Then

getpychar="Z"

Else'如果不是中文,则不处理

getpychar=char

EndIf

EndFunction

%>

【asp 取得中文句子头一个字的大写拼音字母的函数】相关文章:

asp之字符串操作函数

获取字符中中文首字字符

ASP中一个字符串处理类

asp 删除图片与文件函数

计算两个时间之差的函数

一段在asp中加密与解密对应的函数

asp下同一空间多绑多哥域名的方法

在ASP中利用ADO显示Excel文件内容的函数

ASP得到文件的大小类型最后修改时间

asp获取数据库的连接属性的方法

精品推荐
分类导航