Mega Code Archive

 
Categories / C# Book / 02 Essential Types
 

0243 Change string case

We can use ToUpper and ToLower to change the string case. using System; class Sample { public static void Main() { string s = "rntsoft.com"; Console.WriteLine(s.ToUpper()); Console.WriteLine(s.ToLower()); } }