vb.net
I have one textbox and one button. I want that on button click selected text will be reversed
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.
Hiren SoniPosted Dec 27, 2009, 3:50 AM
Kirtan PatelPosted Dec 27, 2009, 3:51 AM
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim str As String = StrReverse(TextBox1.SelectedText)
TextBox1.Text = TextBox1.Text.Replace(TextBox1.SelectedText, str)
End Sub