I have 2 arrays and start off with a "safe" number. At the end of my process i would like to remove empty items, but when i try to compile the code i get the msg "Array already dimensioned" how should i handle this?
Thanks
Private SourceProof(20, 1) As String
Private TargetProof(20, 1) As String
Private Sub removeEmptyItems(isSourceFile As Boolean)
Dim i As Integer
If isSourceFile Then
For i = UBound(SourceProof) To LBound(SourceProof) Step -1
If Len(SourceProof(i, 0) & SourceProof(i, 1)) > 0 Then
ReDim Preserve SourceProof(i - 1, 1)
End If
Next
Else
For i = UBound(TargetProof) To LBound(TargetProof) Step -1
If Len(TargetProof(i, 0) & TargetProof(i, 1)) > 0 Then
ReDim Preserve TargetProof(i - 1, 1)
End If
Next
End If