0

Hi,

I try to change all first letter of the words in the textbox to uppercase.
THis how far i try to change it but just the first word not the entire words.

Private Sub txtQuote_Change()
  txtQuote.Text = UCase$(Left(txtQuote.Text, 1)) & LCase$(Mid$(txtQuote.Text, 2))
  txtQuote.SelStart = Len(txtQuote.Text)
End Sub

Please Help.
Best regards

Thank you.

2
Contributors
2
Replies
4
Views
6 Years
Discussion Span
Last Post by dnk
4

Why not use StrConv()

See if this helps :

Private Sub txtQuote_Change()
  txtQuote.Text = StrConv(txtQuote.Text, vbProperCase)
  txtQuote.SelStart = Len(txtQuote.Text)
End Sub
Votes + Comments
Agree
:D
Very Quckly Response
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.