CSharp examples for System:String Case
Creates a new string with Title Case (ie "hEllO wORLd" becomes "Hello World") using the Invariant Culture
using System.Text.RegularExpressions; using System.Text; using System.Linq; using System.Globalization; using System;// w w w. j a v a 2 s . c o m public class Main{ /// <summary> /// Creates a new string with Title Case (ie "hEllO wORLd" becomes "Hello World") using the Invariant Culture /// </summary> /// <param name="value">The string to convert</param> /// <returns>The string in title case</returns> public static string ToTitleCaseInvariant(this string value) { return ToTitleCase(value, CultureInfo.InvariantCulture); } }