![]() |
Case Flipping
Hello,
I have a richtextbox that I am to be able to type in, I want to be able to select the text and flip the case of the selected string. So... "hello world" would magically be "HELLO WORLD". Here is what I currently have, it does not work, but it does not spit any errors at me. Any ideas? Code:
private void lowerCaseToolStripMenuItem_Click(object sender, EventArgs e) |
Re: Case Flipping
You are just changing the selected text but if nothing is selected its made not to work.
|
Re: Case Flipping
Oh sorry, I forgot to add that I do have something selected.
|
Re: Case Flipping
Try something like this
Code:
rtb.SelectedText = rtb.SelectedText.ToLower(); |
Re: Case Flipping
Nice! It does work thanks a ton. I can't believe that I didn't think of that myself, it's so simple.
|
Re: Case Flipping
Quote:
|
| All times are GMT +5.5. The time now is 08:05. |