|
-
Jan 19th, 2000, 06:34 AM
#1
Thread Starter
Hyperactive Member
Is there some easy way of making it so that when a user enters a letter in a text box that the letter always appears as a capital letter? Or will I have to code something into the KeyPress event that will change the text type? Thanks
------------------
Ryan
-
Jan 19th, 2000, 06:41 AM
#2
Junior Member
You can do the following in the KeyPress event :
KeyAscii = Asc(UCase$(Chr$(KeyAscii)))
This will capitalize all the text that is entered in the textbox.
------------------
Joe Handal
Workstation Engineer
[email protected]
-
Jan 19th, 2000, 06:50 AM
#3
Lively Member
Option 2:
Code:
Private Sub Text1_Change()
Text1 = UCase(Text1)
Text1.SelStart = Len(Text1)
End Sub
All the best.
Chris
-
Jan 20th, 2000, 06:13 AM
#4
Thread Starter
Hyperactive Member
Thank you both. I used both of your suggestions, just to make sure that it gets capitalized.
------------------
Ryan
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|