Valhalla Legends Forums Archive | Visual Basic Programming | Chr() Reference codes

AuthorMessageTime
Topaz
I need a reference to a list of what all the Chr() refer to.
August 2, 2005, 11:25 PM
Yegg
What do you mean by that? A list of all possible values chr() can return? That's what it sounds like to me, correct me if I'm wrong.
August 2, 2005, 11:27 PM
Myndfyr
If that's the case, you could do something like:

(Have a text box called tb on your form)

[code]
Sub Form_Load()
  For i = 1 To 255
    tb.Text = tb.Text & vbCrLf & "Character" & i & ":  " & Chr(i)
  Next
End Sub
[/code]

Note: I skipped 0 because I believe that Windows will stop writing text with the first NULL (Chr(0)).
August 2, 2005, 11:45 PM
Topaz
That crossed my mind, thanks :-]
August 3, 2005, 1:04 AM
K
Start -> Run -> "charmap"

The info bar at the bottom will tell you what the hexadecimal code is for the character. Note that it starts at 0x21 '!', which is the first "printable" character.
You're welcome.
August 3, 2005, 1:17 AM
Archangel
[quote author=K link=topic=12420.msg122897#msg122897 date=1123031821]
Start -> Run -> "charmap"

The info bar at the bottom will tell you what the hexadecimal code is for the character. Note that it starts at 0x21 '!', which is the first "printable" character.
You're welcome.
[/quote]

I didnt knew that :o, awesome. thnx.
August 3, 2005, 3:13 AM
dRAgoN
[quote author=MyndFyre link=topic=12420.msg122882#msg122882 date=1123026318]
If that's the case, you could do something like:

(Have a text box called tb on your form)

[code]
Sub Form_Load()
  For i = 1 To 255
    tb.Text = tb.Text & vbCrLf & "Character" & i & ":  " & Chr(i)
  Next
End Sub
[/code]

Note: I skipped 0 because I believe that Windows will stop writing text with the first NULL (Chr(0)).
[/quote]
Only does that in the .Net output windows
edit: thought you were (debug.print)ing heh
August 4, 2005, 6:58 PM
Tontow
[quote author=Topaz link=topic=12420.msg122879#msg122879 date=1123025155]
I need a reference to a list of what all the Chr() refer to.
[/quote]

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon98/html/vbstartpage.asp look on the left and go additional information->Reference->Charater set
August 5, 2005, 12:51 AM

Search