Duchesssix
New Member
- Joined
- Jan 6, 2011
- Messages
- 42
I have not used arrays yet in VBA. However, I think using an array will be fast then the loop I am using now to determine the row number of the next visible row of autofiltered data.
For example: I filter a set of data on specified fields and the results show the following rows as visible:
2
4
6
7
10
How to I get 2,4,6,7,10 into an array that I can loop through instead of looping for visible rows only.
The followng is what I currently have for code without using an array:
ActiveCell.Offset(1, 0).Select
Do Until ActiveCell.EntireRow.Hidden = False
ActiveCell.Offset(1, 0).Select
Loop
nrow = ActiveCell.Row
intAddress = nrow
For example: I filter a set of data on specified fields and the results show the following rows as visible:
2
4
6
7
10
How to I get 2,4,6,7,10 into an array that I can loop through instead of looping for visible rows only.
The followng is what I currently have for code without using an array:
ActiveCell.Offset(1, 0).Select
Do Until ActiveCell.EntireRow.Hidden = False
ActiveCell.Offset(1, 0).Select
Loop
nrow = ActiveCell.Row
intAddress = nrow