|
-
Jun 5th, 2007, 07:13 AM
#1
Thread Starter
Addicted Member
[RESOLVED] [2005] Forcing Uppser Case in a text box
Hi Everyone,
How do you force all text being inputed (by a user) into a text box to be uppercase?
Last edited by Giraffe Frenzy; Jun 5th, 2007 at 07:23 AM.
-
Jun 5th, 2007, 07:32 AM
#2
Fanatic Member
Re: [2005] Forcing Uppser Case in a text box
vb Code:
private sub myTextBox_KeyUp(sender as object, e as KeyEventArgs)
myTextbox.text = myTextBox.Text.toUpper()
end sub
Note that in case of control & paste the text in the textbox won't be converted.
To do so , write the line in the above sub in the textChangedged event of the textbox
-
Jun 5th, 2007, 07:40 AM
#3
Thread Starter
Addicted Member
Re: [2005] Forcing Uppser Case in a text box
Hi talkro,
I entered your code, but now when I enter data into the text box the data is being entered reversed.
-
Jun 5th, 2007, 07:41 AM
#4
Re: [2005] Forcing Uppser Case in a text box
Set the CharacterCasing property of the textbox to Upper.
I use Microsoft Visual Basic 2005. (Therefore, most code samples I provide will be based around the .NET Framework v2.0, unless otherwise specified)
-
Jun 5th, 2007, 07:43 AM
#5
Thread Starter
Addicted Member
Re: [2005] Forcing Uppser Case in a text box
oh cool. Thanks Ideas Man. That is even better. Thank you.
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
|