Hi everybody, I hope you can give me some help with using an array created in a separate procedure.
I have an array variable that I declared at the top of a module as:
Public RowNumArray() As Long
In procedure Sub EditResources(), I dynamically fill the array with the row numbers of the records that are edited. This is working fine and the array has the correct row numbers.
Later, in a different procedure, I want to do something with those edited rows, which is why I need the row number array but, while the array is still there, it seems to be empty. In the locals window, RowNumArray is listed with the type of Long(), but the value column is completely blank. There is no plus sign in front of the variable name, and no matter what subscript I use, I get a "subscript out of range error.
Can anybody help with this frustrating problem?
Thanks much.
I have an array variable that I declared at the top of a module as:
Public RowNumArray() As Long
In procedure Sub EditResources(), I dynamically fill the array with the row numbers of the records that are edited. This is working fine and the array has the correct row numbers.
Later, in a different procedure, I want to do something with those edited rows, which is why I need the row number array but, while the array is still there, it seems to be empty. In the locals window, RowNumArray is listed with the type of Long(), but the value column is completely blank. There is no plus sign in front of the variable name, and no matter what subscript I use, I get a "subscript out of range error.
Can anybody help with this frustrating problem?
Thanks much.