Force Response to Uppercase Only

  • Thread starter Thread starter Greg
  • Start date Start date
Greg,

Use the UCase() function in the AfterUpdate event of your
text box...

Me!YourTextboxName = UCase(Me!YourTextboxName)

--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
 
How do I force a response to be Uppercase only

In addition to Gary's solution, you can force uppercase as the user types with
code in the control's "KeyPress" event procedure:

'**********EXAMPLE START
Private Sub txtUpper_KeyPress(KeyAscii As Integer)
KeyAscii = Asc(UCase(Chr(KeyAscii)))
End Sub
'**********EXAMPLE END
 
Greg said:
How do I force a response to be Uppercase only

Greg

Greg,
Don't bother.
Let the entry be however the user wishes to enter it.
Code the AfterUpdate event of that control:

[ThisControl] = UCase([ThisControl])
 
Back
Top