Reputation: 883
All,
I'm looking to create a simple app that takes text entered by the user and splits it up, based on what line the text is entered on (it's a multiline textbox) using a comma. It inserts this new comma-delimited value into an output textbox for the user.
I know this may be an embarrassingly easy question, but my VB is very rusty: Is there a built-in VB function that can do this without the use of txt files?
Thanks for your help.
Upvotes: 0
Views: 101
Reputation: 27478
This works for me:
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Me.TextBox2.Text = TextBox1.Text.Replace(vbNewLine, ",")
End Sub
Upvotes: 1