Hi,
First of, this is a nice communtiy here. Lots of info for anyone interested in furthering their knowledge of .NET . I am a career SQA who is looking to enhance his skills by learning a spot of programming, specifically .NET .
On this particular project that I'm working on; I am trying to parse through a text file line by line and counting the number of tabs in each line.
So far this is what I've managed to piece together.
Use a FileStream object to interact with the text file (open/close)
Then use a StreamReader object to read the file line by line using the ReadLine method.
I was thinking of putting the contents of each line as they are read one by one in a hidden ListBox on the form.
Then I can work with each line as I need and when done clear the listBox and move on to the next line in the file.
Assuming that this is reasonably sound so far, how do I count the number of tabs in each line?
I'm not looking for someone to write code for me, I just want to be pointed in the right direction.
If I'm headed in the wrong direction I would appreciate it if you would let me know what it is I'm doing wrong.
Thanx much.
Cheers.
First of, this is a nice communtiy here. Lots of info for anyone interested in furthering their knowledge of .NET . I am a career SQA who is looking to enhance his skills by learning a spot of programming, specifically .NET .
On this particular project that I'm working on; I am trying to parse through a text file line by line and counting the number of tabs in each line.
So far this is what I've managed to piece together.
Use a FileStream object to interact with the text file (open/close)
Then use a StreamReader object to read the file line by line using the ReadLine method.
I was thinking of putting the contents of each line as they are read one by one in a hidden ListBox on the form.
Then I can work with each line as I need and when done clear the listBox and move on to the next line in the file.
Assuming that this is reasonably sound so far, how do I count the number of tabs in each line?
I'm not looking for someone to write code for me, I just want to be pointed in the right direction.
If I'm headed in the wrong direction I would appreciate it if you would let me know what it is I'm doing wrong.
Thanx much.
Cheers.
Last edited: