The C# ToUpperInvariant method is used to convert string into uppercase string using the casing rules of the invariant culture.
Signature
Example
public string ToUpperInvariant()
Parameter
It does not take any parameter
Return
It returns a string.
C# String ToUpperInvariant Method Example
Example
using System;
public class StringExample
{
public static void Main(string[] args)
{
string s1 = "Hello C#";
string s3 = s1.ToUpperInvariant();
Console.WriteLine(s3);
}
}
Output:
Output
HELLO C#