Click here to Skip to main content
15,662,532 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I want to count words in richtextbox live.
Tried this solution but not work after enter key:
Dim w As String() = RichTextBox1.Text.Split(" ".ToCharArray())
 label1.Text = "       Words :- " & w.Length.ToString()  

1 solution

You need to parse the text in order to achieve this. Here's an article that will help: Parsing Sentences and Building Text Statics in Visual Basic[^]
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900