protected bool IsChineseLetter(string input,int index)
{
int code = 0;
int chfrom = Convert.ToInt32("4e00", 16); //Convert range (0x4e00~0x9ff) to int (chfrom~chend)
int chend = Convert.ToInt32("9fff", 16);
if (input != "")
{
code = Char.ConvertToUtf32(input, index); //Get the character unicode encoding at the specified index in the string input
if (code >= chfrom && code <= chend)
{
return true; //Return true when code is within the Chinese range
}
else
{
return false ; //Return false when the code is not in Chinese
}
}
return false;
}