Setting a text field to first letter UpperCase

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How can I format a text box to start with Uppercase first letter. I am using
the text box to capture names and would like to start them with a capital
letter and then the remaining as lower case.
 
Jack, you can do this in the AfterUpdate event procedure of the text box as
shown below.

However, this is still going go give you problems with people such as:
van Leen
Von Trap
McDonald

Private Sub Text1_AfterUpdate
With Me.[Text1]
If Len(.Value) > 1 Then
.Value = StrConv(Left(.Value,1), vbUpperCase) & Mid(.Value, 2)
End If
End With
End Sub
 
Back
Top