|
-
Nov 11th, 2000, 09:41 PM
#1
How do I capitalize the first word a sentence, is there a built in function to take care of it, or what?
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Nov 11th, 2000, 09:58 PM
#2
PowerPoster
here one that will capitalize the first word in a text box. Is this what you want or something else?
Private Sub Command1_Click()
m$ = Left(Text1.Text, 1)
c$ = UCase(m$)
i$ = Replace(Text1.Text, m$, c$)
Label1.Caption = i$
End Sub
-
Nov 11th, 2000, 10:05 PM
#3
Dazed Member
There is probably a million was to do this but i felt a
bit creative so i went with this.
Private Sub Command1_Click()
Dim orgmessage As String
Dim newmessage As String
Dim capletter As String
orgmessage = "hello my name is brandon"
capletter = UCase(Left(orgmessage, 1))
newmessage = Mid(orgmessage, 2, Len(orgmessage))
Picture1.Print orgmessage
Picture1.Print (capletter + newmessage)
End Sub
-
Nov 11th, 2000, 10:11 PM
#4
Member
Text1 = StrConv(Text1, vbProperCase)
-
Nov 12th, 2000, 12:53 AM
#5
Originally posted by d.paulson
Text1 = StrConv(Text1, vbProperCase)
This Will Capitalize The First Letter Of Every Word In The Sentence.
-
Jul 13th, 2016, 11:08 AM
#6
New Member
Re: capitalize first letter
 Originally Posted by ;161035
This Will Capitalize The First Letter Of Every Word In The Sentence.
Yea Some People Don't Bother to READ!!
-
Jul 13th, 2016, 11:49 AM
#7
New Member
Re: capitalize first letter
 Originally Posted by crptcblade
How do I capitalize the first word a sentence, is there a built in function to take care of it, or what?
sString =UCase$(Left(sString, 1)) & Mid(sString, 2, Len(sString))
-
Jul 13th, 2016, 12:30 PM
#8
Re: capitalize first letter
 Originally Posted by AffiliateSwitchblade
Yea Some People Don't Bother to READ!!
And some do not bother to read the date then respond to a 16 year old question 
But since it has been dug up here is another method that is perhaps a bit more efficient than the others given
Code:
Mid$(sString, 1, 1) = UCase$(Left$(sString, 1))
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|