![]() |
How do I convert char into integer in Excel VBA?
Hi all,
I am trying to do a little programming exercise with Excel VBA, I have seen the way that converting integer into char and I want to try the way that converting char into integer. I was using Int() as the converter... but after I have seen the spec and I noticed that I was wrong of using this function. I tried to subtract the char with 64, well... stupit me and the type was not match LOL. So that, is it possible to convert char into int in any other way? Thanks |
How do I convert char into integer in Excel VBA?
Sub test() MsgBox Asc("a") End Sub will display 97 that is the ASCII integer for "a". Do NOT do this in the spreadsheet: =ASC("a") -- raypayette ------------------------------------------------------------------------ raypayette's Profile: http://www.excelforum.com/member.php...o&userid=29569 View this thread: http://www.excelforum.com/showthread...hreadid=563544 |
How do I convert char into integer in Excel VBA?
Thanks mate. I have been looking for this function for a long time.
"raypayette" wrote: Sub test() MsgBox Asc("a") End Sub will display 97 that is the ASCII integer for "a". Do NOT do this in the spreadsheet: =ASC("a") -- raypayette ------------------------------------------------------------------------ raypayette's Profile: http://www.excelforum.com/member.php...o&userid=29569 View this thread: http://www.excelforum.com/showthread...hreadid=563544 |
All times are GMT +1. The time now is 08:23 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com