[VB 2005] Parser help involving a 2d array
I am attempting to use a parser to read a text file. Then I am wanting that information to be stored into an 2d array. The problem is that the program will not run because it tells me that a parser can only be a 1d array. Does anyone know a way around this?
Code:
Dim CPI As String = "c:\champ.txt"
Dim fields1 As String(,)
Dim delimiter As String = ""
Dim rownumber As Integer
Using parser As New TextFieldParser(CPI)
parser.SetDelimiters(delimiter)
While Not parser.EndOfData
' Read in the fields for the current line
fields1 = parser.ReadFields()
End While
end using
The main part I am having a problem with is in bold
|