Code for find the ascii value of character
how we can find the ascii value in c# code means if code is "c","d" etc.. how we find the ascii value through c # code in web application
3 Answers
Know the answer? Post it. Somebody with the same question will find it here.


Jaganathan BantheswaranRank #170 · 14.1K reputationPosted Nov 3, 2014, 12:54 AM EST
You can do something like this,
string str = "Jaganthan";
byte[] asciis = Encoding.ASCII.GetBytes(str);
foreach(byte b in asciis ) {
Console.WriteLine(b); // ASCII value
}
VulpesRank #55 · 29.2K reputationPosted Nov 3, 2014, 1:46 AM EST
Riddhi ValechaRank #794 · 2.9K reputationPosted Nov 3, 2014, 2:32 AM EST