Tuesday, January 6, 2009

How to convert strings to lower, upper, titlecase

string str = "xploReDOtneT wElcomeS yOU";

Response.Write("Orginal Text:- " + str + "
Lower :- " + str.ToLower() + "
" + "Upper :- " + str.ToUpper() + "
" + "Title Case :- " + System.Globalization.CultureInfo.CurrentCulture.TextInfo.ToTitleCase(str));



OUTPUT



Orginal Text:- xploReDOtneT wElcomeS yOU

Lower :- xploredotnet welcomes you

Upper :- XPLOREDOTNET WELCOMES YOU

Title Case :- Xploredotnet Welcomes You



No comments:

Creative Commons License
Disclaimers:We have tried hard to provide accurate information, as a user, you agree that you bear sole responsibility for your own decisions to use any programs, documents, source code, tips, articles or any other information provided on this Blog.