This documentation is archived and is not being maintained.

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".

Requirements

Namespace: Microsoft.VisualBasic

Module: Strings

Assembly: Microsoft Visual Basic .NET Runtime (in Microsoft.VisualBasic.dll)

See Also

Strings | String Manipulation | LCase Function

Show: