Click here to Skip to main content
15,883,883 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Ok, I posted this earlier but seems no one has understood me, now I will give a simple eich have the word "love" must appear in the another multiline textbox.
I have a simple streamreader code, but its not that Im searching. Im new in Visual basic, please help!
Posted
Updated 5-May-11 13:19pm
v4

1 solution

Modify the 'simple streamreader' code you have:
  1. Read the text a line at time.
  2. Search for the given word inside the read line.
  3. If the line contains word then add it to the multiline textbox.
 
Share this answer
 
Comments
555336 25-Mar-11 7:01am    
Well the word "love" is only an example, the user can search other words also! I don't know how to put the coding.
CPallini 25-Mar-11 7:04am    
To start: In the btnOK click handler, set a variable with txtSearch.Text then use it for searching inside read lines (i.e. 'GimmeCode' is not welcomed, please show us your effors...).
555336 25-Mar-11 7:10am    
that
CPallini 25-Mar-11 7:21am    
You have to read a line at time, see the following example: http://msdn.microsoft.com/en-us/library/db5x7c0d.aspx
555336 25-Mar-11 7:25am    
Yes...I did see this tutorial, the onlu thing is that this code will be in the btnOK event where the user has to click on it and get the results, but the only problem I'm having, I dont know know how to do a code for the textbox where the user will put a word then click on the button to search.

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