Login or Sign Up
Logging in...
Remember me
Log in
Or
Sign Up
Forgot password or user name?
Log in with
Search in titles only
Search in .NET only
Search
Advanced Search
Forums
BYTES
Product Launch
Updates
Developer Toolkit
Today's Posts
Member List
Calendar
Home
Forum
Topic
.NET
ASCII Code
Collapse
X
Collapse
Posts
Latest Activity
Photos
Page
of
1
Filter
Time
All Time
Today
Last Week
Last Month
Show
All
Discussions only
Photos only
Videos only
Links only
Polls only
Events only
Filtered by:
Clear All
new posts
Previous
template
Next
gsgurdeep
New Member
Join Date:
Apr 2007
Posts:
94
#1
ASCII Code
Oct 1 '07, 06:27 AM
Please tell me the method of finding ASCII code for a giving letter in VB.Net program.
Help Me.
hariharanmca
Top Contributor
Join Date:
Dec 2006
Posts:
1977
#2
Oct 1 '07, 06:38 AM
Originally posted by
gsgurdeep
Please tell me the method of finding ASCII code for a giving letter in VB.Net program.
Help Me.
You can get key Code in KeyDown and KeyUp Events of a control
and KeyAscii in KeyPress event
use But Key Char is not available in KeyPress event
[CODE=vbnet]intAsciiValue = Asc(Keys.KeyCha r)[/CODE]
There is another Code like
[CODE=vbnet]intAsciiValue = Keys.KeyCode[/CODE]
Comment
Post
Cancel
Plater
Recognized Expert
Expert
Join Date:
Apr 2007
Posts:
7872
#3
Oct 1 '07, 01:19 PM
If you have an ASCII character, you can type-cast it to an int (or to a byte if you feel like it) and then look at the value.
Here's a chart of the common ASCII character values
http://www.ascii.ws/images/ascii-chart.gif
Comment
Post
Cancel
Previous
template
Next
Working...
Yes
No
OK
OK
Cancel
👍
👎
☕
Comment