Lost Focus-Converting to Upper Case

sales@scantechintl.com

Registered User.
Local time
Today, 04:30
Joined
Oct 31, 2000
Messages
24
After typing in alpha data, how can I convert it AFTER losing focus.

Do I have to set an input mask? I need to know the code.

Thank you,
John
 
Here is what I use

This is the code that I use ... it seems to work ok.

Me.YourField = UCase(Me.txtYourField)


Steve
 
why after the focus has left? why not disallow your users from entering lower case letters in the field in the first place?

Code:
Private Sub Text0_KeyPress(KeyAscii As Integer)
If KeyAscii > 96 And KeyAscii < 123 Then
KeyAscii = Asc(UCase(Chr(KeyAscii)))
End If
End Sub
 

Users who are viewing this thread

Back
Top Bottom