You can use the following code to automatically Title Case text entered in a text box as you enter it. Put the code on the On Key Press event.
--------
Static CapNext As Integer
Set myControl = Screen.ActiveControl
If myControl.Text = "" Then
KeyAscii = Asc(UCase$(Chr$(KeyAscii)))
CapNext = False
ElseIf KeyAscii = 32 Then '-Space = 32
CapNext = True
ElseIf CapNext Then
KeyAscii = Asc(UCase$(Chr$(KeyAscii)))
CapNext = False
End If
Exit Sub
--------
This is a tight little procedure that works well (and fast). Please note that it does not handle backspaces or special cases, e.g. Names McDonald, MacDonald, or Addresses NW. Not withstanding these limitations, our clients love this little routine.
We use some functions to handle these special cases on the Text Box's After Update Event.
If you would like to see these, please let me know.
Good Luck! If you have any questions, please let me know.