What do you mean?
It is simple as 1-2-4 (sorry, 1-2-3
![Smile :) :)](/styles/default/custom/smilies/smile.gif)
)
just like in C, C++ (etc.) a char is a datatype of 1 byte, that can be
converted to any other (native) datatype that is larger (int, short,
long, byte, etc...) by just casting it...
You can also try this:
int nASCII = Convert.ToInt32 ('A');
long lASCII = Convert.ToInt64 ('B');
short sASCII = Convert.ToInt16 ('C'); //short==16 bits? (I though so)
--
NULL
"NULL" <Thomas-dot-Delrue-at-Tiscali-dot-Be> wrote in message
On Tue, 2 Sep 2003 18:48:39 +0800, "Peter Z"
Hello folks,
Does anyone know the equivalent VB Asc function for C#?
Or ways around it?
try this
int nASCII = (int)'A'; //should give 65 or 91 or something like
//that...?
int nASCII2 = (int)myCharVariable;
int nASCII3 = (int)myString[1]; //second char in string