Discussion Locked

Changing Characters

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
How do I create the code to get a name that was enter into a textbox to change the First letter to a Capital.

5 replies

by sl-campbell

Dim sInput As String

sInput = Text1.Text

sInput = UCase$(Left$(sInput,1)) & Mid$(sInput,2)

Text1.Text = sInput

'If you put this in the Text1 Change or Validate events you should set a boolean variable when changing the value of Text1.Text to keep the event from executing again.

This discussion is closed to new replies.