Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
RaY RaY is offline
external usenet poster
 
Posts: 164
Default 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
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default 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

  #3   Report Post  
Posted to microsoft.public.excel.misc
RaY RaY is offline
external usenet poster
 
Posts: 164
Default 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


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I convert Excel 2003 to Excel 98 format? Lady Layla New Users to Excel 8 March 31st 05 12:47 AM
How can I convert an Excel file to someone who doesn't have Excel. donnythejazz Excel Discussion (Misc queries) 3 March 30th 05 11:59 PM
How do I convert a csv file to an Excel file? Anne B Excel Discussion (Misc queries) 2 March 29th 05 09:17 PM
Convert HTML into an Excel skydiving99 Excel Worksheet Functions 1 March 18th 05 11:35 PM
Improve Convert function in Excel Mike VV Excel Worksheet Functions 0 February 3rd 05 04:45 AM


All times are GMT +1. The time now is 01:58 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"