How can i set first char in capital...
How can i set first character in capital in textbox..
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Pankaj Kumar ChoudharyPosted Mar 26, 2015, 9:29 AM
if (textBox2.Text.Trim().Length == 1)
{
textBox2.Text = textBox2.Text.ToUpper();
textBox2.SelectionStart = textBox2.Text.Length;
}
Feroz KhanPosted Mar 26, 2015, 8:50 AM
Khargesh RajputPosted Mar 26, 2015, 8:15 AM
Pankaj Kumar ChoudharyPosted Mar 26, 2015, 7:32 AM
private void textBox2_TextChanged(object sender, EventArgs e)
{
if (textBox2.Text.Trim().Length == 1)
{
textBox2.Text = textBox2.Text.ToUpper();
}
}