Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Numeric Input
Message
General information
Forum:
ASP.NET
Category:
Other
Title:
Miscellaneous
Thread ID:
01156834
Message ID:
01158463
Views:
30
>I am currently correcting lowere case characters with TO Upper on RETURN key
>
>My client wants it converted as it goes in
>
>Some code I tried UPPERS the previous input which is OK but then adds the new input at the beinning!!!
>
>R

did you try this code
private void textBox1_TextChanged(object sender, EventArgs e)
{
  ((TextBox)sender).Text = ((TextBox)sender).Text.ToUpper();
  ((TextBox)sender).SelectionStart = ((TextBox)sender).Text.Length;
}
the 2nd line (((TextBox)sender).SelectionStart = ((TextBox)sender).Text.Length;)moves the cursor to the end.
Semper ubi sub ubi.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform