Visual Basic Language Reference  

UCase Function

Returns a string or character containing the specified string converted to uppercase.

Public Shared Function UCase(ByVal Value As Char) As Char

-or-

Public Shared Function UCase(ByVal Value As String) As String

Parameter

Value
Required. Any valid String or Char expression.

Remarks

Only lowercase letters are converted to uppercase; all uppercase letters and nonletter characters remain unchanged.

Example

This example uses the UCase function to return an uppercase version of a string.

Dim LowerCase, UpperCase As String
LowerCase = "Hello World 1234"   ' String to convert.
UpperCase = UCase(LowerCase)   ' Returns "HELLO WORLD 1234".

See Also

LCase Function