I am trying to prevent some characters from being uppercase, while all others has to be.
For an example if I write something in the textbox, it automatically writes all characters uppercase, but everytime I enter the letter "k" it has to be lowercase.
Does any one know a way of achieving this?
private void textBox3_TextChanged(object sender, EventArgs e)
{
// Navn/Name Text Box
}
In your
textBox3_TextChanged
event handler you can simply "correct" the text and set it back.You'll have to remember the cursor position (and selection) so that the user does not get interrupted while typing:
Note: this is for Windows.Forms. I guess for wpf or asp or other ui frameworks the part with the cursor handling will differ.