Capitalise the first letter of a string




Capitalise the first letter of a string
If you would like to capitalise the first letter of a string, do as I have done in the below example:
  1. Dim strString As String = "string text"  
  2.   
  3. Textbox1.Text = UCase(Left(strString,1)) & Mid(strString,2)  
The above example converts 'string text' to 'String text' and then put the converted string into a textbox called 'Textbox1'.

1 person likes this article, click here to say you like this article too (1)
Send a link to this page via email Send a link to this page