underwar
March 2nd, 2003, 09:02 AM
I'm trying to make the following lines to work:
int i = int.Parse("0xA");
Console.WriteLine(i);
i.e: i want parse to take the hex number, convert it to int and print it.
As I read in the manual, we can add another parameter to Parse - FormatProvider, that will do the task, but I can't understand how to use that FormatProvider.
Anyone has a solution?
int i = int.Parse("0xA");
Console.WriteLine(i);
i.e: i want parse to take the hex number, convert it to int and print it.
As I read in the manual, we can add another parameter to Parse - FormatProvider, that will do the task, but I can't understand how to use that FormatProvider.
Anyone has a solution?