Using VB 2008, I need help extracting text from a loaded text file. I turn the text into a string and know I will need to use split() in there but I'm unsure how to go about this properly and was hoping someone could point me to some code snippets or let me know which functions I should be looking at and how to approach this.

The text will be of varying length and I need to strip out certain information. In this example, the information needed will be between two tags.. ie <x>sometext</x>

I need to get all of the text in between those tags. Additionally, the file will be of varying lengths, so the tags can repeat an unlimited # of times.

In this file the text is xml however I will need to do the same on other files which will not be xml, therefore using some of the xml parsing code I've found wouldn't work.

Can anyone help out?