Browse DevX
Sign up for e-mail newsletters from DevX

Tip of the Day
Language: C#
Expertise: Beginner
Mar 2, 2007

Make a Textbox Display Characters in a Particular Case

Making a textbox display its characters in a particular case (upper, lower, or title) is very easy with the help of the CharacterCasing property, which uses the values of the enum Forms.CharacterCasing.

In the following example, CharacterCasing is used to display all typed characters in uppercase:

textBox1.CharacterCasing = System.Windows.Forms.CharacterCasing.Upper;
You can also set this at design time.

Srinath MS
Thanks for your registration, follow us on our social networks to keep up-to-date