I am struggling with a program I'm creating for Excel using VBA. The ultimate intent of the program is to read specific elements of a text file into an Excel spreadsheet based upon the user's selection of one of those elements through a userform listbox. Please refer to my code below which is for the section of my program pertaining to 1) populating the listbox with the job set numbers and 2) populating specific arrays containing the desired data I need from the very large comma-delimited text file:

```
Private Sub UserForm_Initialize()
    'Declare variables
    Const CMMData As String = "\\ATSTORE01\CMMData\21064D\21064D-OP400.dat"
    Dim strSN() As String
    Dim strSet() As String
    Dim strFF() As String
    Dim strVHCC() As String
    Dim strVHCCMID() As String
    Dim strVHCVMID() As String
    Dim strVHCV() As String
    Dim strHWCC() As String
    Dim strHWCCMID() As String
    Dim strHWCVMID() As String
    Dim strHWCV() As String
    Dim LineData As String
    Dim SplitData() As String
    Dim LineIter As Long
    'Populate Set Number Listbox
    With New Scripting.FileSystemObject
        With .OpenTextFile(CMMData, ForReading)
            Do Until .AtEndOfStream
                LineData = .ReadLine
                SplitData = Split(LineData, ",", 154, vbTextCompare)
                'Extracting Serial Number
                ReDim Preserve strSN(0 To LineIter)
                strSN(UBound(strSN)) = SplitData(0)
                'Extracting Set Number
                ReDim Preserve strSet(0 To LineIter)
                strSet(UBound(strSet)) = SplitData(1)
                'Extracting Final Flow Area
                ReDim Preserve strFF(0 To LineIter)
                strFF(UBound(strFF)) = SplitData(14)
                'Extracting /V/ To Hook CC
                ReDim Preserve strVHCC(0 To LineIter)
                strVHCC(UBound(strVHCC)) = SplitData(31)
                Set_Select.AddItem SplitData(1)
                LineIter = LineIter + 1
            Loop
            .Close
        End With
    End With
    For LineIter = LBound(strFF) To UBound(strFF)
        MsgBox strFF(LineIter)
    Next LineIter
End Sub

```

The area of the above code where I am having trouble is as follows:

```
'Extracting /V/ To Hook CC
ReDim Preserve strVHCC(0 To LineIter)
strVHCC(UBound(strVHCC)) = SplitData(31)

```

The code populates the split arrays up to (30). For arrays (31) and above, I get a "Subscript out of range" error. I have spent considerable time trying to determine the error but have been unsuccessful. I am also quite new to working with arrays so I have been teaching myself much over the past week but still have much to learn.

I greatly appreciate the help. Thank you.