Vb.net
I have one textbox and one button. I want that on button click selected text will be reversed
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend4days leftRegister
Hiren SoniRank #694 · 3.5K reputationPosted Dec 26, 2009, 10:50 PM EST
Kirtan PatelRank #292 · 8.6K reputationPosted Dec 26, 2009, 10:51 PM EST
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