LCKB
[visualbasic]convert string to integer - Printable Version

+- LCKB (https://lckb.dev/forum)
+-- Forum: ** OLD LCKB DATABASE ** (https://lckb.dev/forum/forumdisplay.php?fid=109)
+--- Forum: Programmers Gateway (https://lckb.dev/forum/forumdisplay.php?fid=196)
+---- Forum: Coders Talk (https://lckb.dev/forum/forumdisplay.php?fid=192)
+---- Thread: [visualbasic]convert string to integer (/showthread.php?tid=1824)



- soryjero - 05-20-2013


i am trying to read a string from a text file with this line:

 

test = fileReader.ReadLine()

 

after this, test = 0AF4B210

 

and i want to convert this to a integer.

 

how could i do this?

 

i have been trying with differents functions from system, but i havent got it.

 

anybody can help me please?

 

p.s. i use visual studio 2010




- Wizatek - 05-20-2013


in C# its,

Convert.ToIn32(string, base)

so it would be something like

 

Convert.ToInt32("0AF4B210", 16);




- soryjero - 05-20-2013



in C# its,

Convert.ToIn32(string, base)

so it would be something like

 

Convert.ToInt32("0AF4B210", 16);

 

thanks so much wiza Smile