Just starting to get my head around VB and i've managed to get a small program to open a text file, read the first line and split each word in the sentence into several different text boxes on a GUI. i press a button on my GUI and it opens the text file, splits the line into each word and drops it into text boxes, code i use is below. instead of splitting by a space (as in this example) is it possible in a similar way to split by particular words in that sentence instead? i noticed somewhere that i could use LineOfText.Split(" "c) where the "c" indicates a character but W for word or anything else doesn't work.

Any pointers would be apprechiated!

------------
Dim FILE_NAME As String = "C:\text2.txt"
Dim TextLine As String

If System.IO.File.Exists(FILE_NAME) = True Then

Dim objReader As New System.IO.StreamReader(FILE_NAME)

Do While objReader.Peek() <> -1
TextLine = TextLine & objReader.ReadLine() & vbNewLine
Loop

TextBox1.Text = TextLine

Dim LineOfText As String
Dim aryTextFile() As String

LineOfText = TextLine

aryTextFile = LineOfText.Split(" ")
TextBox1.Text = aryTextFile(0)
TextBox2.Text = aryTextFile(1)

Else

MsgBox("File Does Not Exist")

End If

------------------