All articles| All Pictures| All Softwares| All Video| Go home page| Write articles| Upload pictures

Reading number is top 10 articles
IIS同一站点下aps.net,1.1与2.0,共存方法_[Asp.Net教程]
图片在已知大小容器中的水平垂直居中实例_[Html教程]
在Web.config配置文件中自定义配置节点_[Asp.Net教程]
在ASP.NET中实现Url,Rewriting_[Asp.Net教程]
ASP.NET导出文件及,HTTP头信息,文件类型对照_[Asp.Net教程]
javascript特效:将HTML自动转为JS代码_JavaScript技术_编程技术
Web.config简要配置说明_[Asp.Net教程]
SQL Server无法打开用户默认数据库_[SQL Server教程]
ASP.NET技巧:在存储过程中实现分页_.net资料_编程技术
MS SQL 2005的新功能创建数据库快照_[SQL Server教程]
Reading number is top 10 pictures
哥斯达黎加的门将是如何练成的
10 powerless things in life
Female model behind the bitterness, often being overcharged4
小学生作文又现神作,你不得不佩服
30 beautiful school beauty5
The mother was a stay-at-home children too tired took three baby suicide
Average female college students2
Absolutely shocked. National geographic 50 animal photographys9
In 2013 hercules Arnold classic2
Go to the national museum2
Download software ranking
实战黑客不求人
美女游泳记
Boxer's Top ten classic battle6
Unix video tutorial9
传奇私服架设教程
豪门浪荡史
传奇私服架设教程-chm
变速齿轮3.26
美女写真2
Call Of Duty5
归海一刀 published in(发表于) 2014/1/30 1:24:14 Edit(编辑)
asp.net自动生成姓名拼音的代码_[Asp.Net教程]

asp.net自动生成姓名拼音的代码_[Asp.Net教程]

asp.net自动生成姓名拼音的代码_[Asp.Net教程]
public string GetPYString(string str)
{
string tempStr = "";
foreach(char c in str)
{
if((int)c >= 33 && (int)c <=126)
{//字母和符号原样保留
tempStr += c.ToString();
}
else
{//累加拼音声母
tempStr += GetPYChar(c.ToString());
}
}
return tempStr;
}

///
/// 取单个字符的拼音声母
/// Code By MuseStudio@hotmail.com
/// 2004-11-30
///

/// 要转换的单个汉字
/// 拼音声母
public string GetPYChar(string c)
{
byte[] array = new byte[2];
array = System.Text.Encoding.Default.GetBytes(c);
int i = (short)(array[0] - ’\0’) * 256 + ((short)(array[1] - ’\0’));

if ( i < 0xB0A1) return "*";
if ( i < 0xB0C5) return "a";
if ( i < 0xB2C1) return "b";
if ( i < 0xB4EE) return "c";
if ( i < 0xB6EA) return "d";
if ( i < 0xB7A2) return "e";
if ( i < 0xB8C1) return "f";
if ( i < 0xB9FE) return "g";
if ( i < 0xBBF7) return "h";
if ( i < 0xBFA6) return "g";
if ( i < 0xC0AC) return "k";
if ( i < 0xC2E8) return "l";
if ( i < 0xC4C3) return "m";
if ( i < 0xC5B6) return "n";
if ( i < 0xC5BE) return "o";
if ( i < 0xC6DA) return "p";
if ( i < 0xC8BB) return "q";
if ( i < 0xC8F6) return "r";
if ( i < 0xCBFA) return "s";
if ( i < 0xCDDA) return "t";
if ( i < 0xCEF4) return "w";
if ( i < 0xD1B9) return "x";
if ( i < 0xD4D1) return "y";
if ( i < 0xD7FA) return "z";

return "*";
}


添加到del.icio.us 添加到新浪ViVi 添加到百度搜藏 添加到POCO网摘 添加到天天网摘365Key 添加到和讯网摘 添加到天极网摘 添加到黑米书签 添加到QQ书签 添加到雅虎收藏 添加到奇客发现 diigo it 添加到饭否 添加到飞豆订阅 添加到抓虾收藏 添加到鲜果订阅 digg it 貼到funP 添加到有道阅读 Live Favorites 添加到Newsvine 打印本页 用Email发送本页 在Facebook上分享


Disclaimer Privacy Policy About us Site Map

If you have any requirements, please contact webmaster。(如果有什么要求,请联系站长)
Copyright ©2011-
uuhomepage.com, Inc. All rights reserved.