Read muli field, multi line text file into 2D string array
Posted on 2004-09-02
I have a text file that looks like this....
'314' 'TM15025.PV' 'ON' 'N/A' 'N/A' 'N/A'
'312' 'TM15025.PV' 'ON' 'N/A' 'N/A' 'N/A'
'315' 'TM16027.PV' 'ON' 'N/A' 'N/A' 'N/A'
'316' 'TM16028.PV' 'ON' 'N/A' 'N/A' 'N/A'
I want to have a 2D array that has all this info.
strArray(0,0) would equal '314'
strArray(0,1) would equal 'TM15025.PV'
I was thinking
Dim i as Integer
Do While EOF(1)
Redim Preserve strArray(i, 6)
<Some how read the line into the array>
i = i + 1