I think the title says enough.
void onClickSubmit(char submit)
{
if(submit.//check if it is alphabetical)
{
//some code
}
}
how can i check if the char submit is in the alphabet?
I think the title says enough.
void onClickSubmit(char submit)
{
if(submit.//check if it is alphabetical)
{
//some code
}
}
how can i check if the char submit is in the alphabet?
You can use regex if your alphabet are only A-Z or a-z
char a = 'A';
bool isAlphaBet = Regex.IsMatch(a.ToString(), "[a-z]", RegexOptions.IgnoreCase);
if(isAlphaBet )
{
//do this..
}
To support any UTF-8 Letter
var rgx = new Regex(@"[\p{L}]");
Console.Write(rgx.Match("Ö").Success);