I have looked all over, and can't seem to find an answer to my problem.
I have a multidimensional array that has values I want to exclude, but don't understand the Redim function enough to write the code. Can someone please help me?
AF_Vals = (0 to 6, 0 to 1)
When I populate data into AF_Vals if a dimension contains either "Resize" or "Number" in the string, I want those removed from the array, and those values are always at the beginning of the array. Is there a way to remove the lower bounds of the array that contain those strings? Thanks in advance.
I have a multidimensional array that has values I want to exclude, but don't understand the Redim function enough to write the code. Can someone please help me?
AF_Vals = (0 to 6, 0 to 1)
VBA Code:
For lngVal = 0 To UBound(AF_Vals, 1)
strTest = Left(AF_Vals(lngVal, LBound(AF_Vals, 2)), 6)
If strTest <> "Resize" And strTest <> "Number" Then Exit For
Next lngVal
ReDim Preserve AF_Vals(LBound(AF_Vals, 1) + lngVal To UBound(AF_Vals, 1), 0 To 1)
When I populate data into AF_Vals if a dimension contains either "Resize" or "Number" in the string, I want those removed from the array, and those values are always at the beginning of the array. Is there a way to remove the lower bounds of the array that contain those strings? Thanks in advance.