How to Change First Letter of Each Word to Capital

Aa example to change first letter of each word in phrase to capital. You can do this by explicitly converting first letter to caps and then append rest of word to it or you can do this.
System.Threading.Thread.CurrentThread.CurrentCulture.TextInfo.ToTitleCase("simple sentence")

//will return
// Simple Sentence
Subscribe for our monthly newsletter for updated articles and useful code scripts.

Share It

comments powered by Disqus
Chat With Us Close
Leave Message