Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / C# / May 2007

Tip: Looking for answers? Try searching our database.

How to convert string to InitCap

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Timoti - 11 May 2007 18:23 GMT
Given any string variable in C#, how to convert the result into Initial
Capitals?

Ex: Given, "how are you?" to be converted as "How Are You?"
Signature

God bless you for the help

Chakravarthy - 11 May 2007 18:26 GMT
use the following method

public static string PropCase(string strText)
{
return new
CultureInfo("en").TextInfo.ToTitleCase(strText.ToLower());
}

And dont post twice any question....
Signature

Every thing is perfect, as long as you share!!!

Don''t forget to rate the post

> Given any string variable in C#, how to convert the result into Initial
> Capitals?
>
> Ex: Given, "how are you?" to be converted as "How Are You?"
Timoti - 11 May 2007 18:34 GMT
Thanks for the reply, unfortunately, i couldn't see the post, hence is the
second time.
Will take care from the next time
Signature

God bless you for the help

> use the following method
>
[quoted text clipped - 10 lines]
> >
> > Ex: Given, "how are you?" to be converted as "How Are You?"

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.