Hi guys,
Is there a way to replace the new-line character in a textbox?
I've attached a sample file with expected result.
Thank you.
Hi guys,
Is there a way to replace the new-line character in a textbox?
I've attached a sample file with expected result.
Thank you.
.. and don't forget to have fun!
Bogdan.
mark SOLVED andAdd Reputation if my answer pleases you
You have both vbCr and vbLf, so your code should be
![]()
If InStr(TextBox1.Text, vbCrLf) > 0 Then Label1.Caption = Replace(TextBox1.Text, vbCrLf, "") End If
If you are pleased with a member's answer then use the Star icon to rate it.
Replace this
With![]()
Replace(TextBox1.Text, Chr(10), "")
Edit: Slow Testing/Typing![]()
Replace(TextBox1.Text, vbCrLf, " ")
![]()
If your problem is solved, then please mark the thread as SOLVED>>Above your first post>>Thread Tools>>
Mark your thread as Solved
If the suggestion helps you, then Click *below to Add Reputation
Thanks a bunch!
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks