Wednesday, September 9, 2015

Convert String to Title Case (Proper Case) in .Net C#


C# Code (by default, English Culture):
 


CultureInfo culinfo = Thread.CurrentThread.CurrentCulture;

TextInfo txtinfo = culinfo.TextInfo;
lblResult.Text = txtinfo.ToTitleCase("AMIT JAIN");


OutPut: 
Amit Jain

No comments:

Post a Comment