3 Replies - 2226 Views - Last Post: 14 January 2010 - 12:32 AM

#1 iwantthependrive   User is offline

  • New D.I.C Head
  • member icon

Reputation: 0
  • View blog
  • Posts: 12
  • Joined: 15-February 09

Convert a character to its ASCII code and back

Posted 25 April 2009 - 07:40 AM

Description: make 2 command buttons (default names)for example a is 97, A is 65 ,[space] is 32,etc.
'this converts the character to ASCII
Private Sub Command1_Click()
Dim a As String
a = (InputBox("Enter a character"))
b = Asc(a)
c = MsgBox(b)
End Sub
'this converts the ASCII number to normal
Private Sub Command2_Click()
Dim a As Long
a = (InputBox("Enter a number"))
b = Chr(a)
c = MsgBox(b)
End Sub


Is This A Good Question/Topic? 0
  • +

Replies To: Convert a character to its ASCII code and back

#2 boka3090   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 0
  • Joined: 08-January 10

Re: Convert a character to its ASCII code and back

Posted 08 January 2010 - 10:00 AM

thanks
Was This Post Helpful? 0
  • +
  • -

#3 iwantthependrive   User is offline

  • New D.I.C Head
  • member icon

Reputation: 0
  • View blog
  • Posts: 12
  • Joined: 15-February 09

Re: Convert a character to its ASCII code and back

Posted 14 January 2010 - 12:32 AM

welcome! :)
Was This Post Helpful? 0
  • +
  • -

#4 iwantthependrive   User is offline

  • New D.I.C Head
  • member icon

Reputation: 0
  • View blog
  • Posts: 12
  • Joined: 15-February 09

Re: Convert a character to its ASCII code and back

Posted 14 January 2010 - 12:32 AM

welcome! :)
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1