0

I want to Split the the text in the RichTextBox per line into array in vb.net if i show array(0) it will show the first line of richtextbox, array(1) will show the second line and go on.

Im new in VB and I cant find any decent link or site. Thanks in advance for help.

1 Answer 1

1

Your Richtextbox has a property called Lines (link). Which returns an String() where each line is a new entry in the Array. More info can be found in the link above.

Code example

Dim myArr As String() = MyRichTextBox.Lines

Note: Searching "Richtextbox to array" (in google) does supply you with plenty of helpful webpages

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.