ShawnExcel
Member
Here is what I'm attempting to do. I have a list of 200 names, and I have a filter on that shows only 5 of them. I want the code to filter through the list, skip hidden rows, and write those five names (and the info associated with them) to another worksheet. Here is what I have so far. I think my issue is in the "If c.EntireRow.Hidden".... section. It doesn't loop back up and check again if the next row is hidden so if I have two hidden rows, it will still print the second one but ignore the first. I need it to check whether the active cell is hidden another time, after doing it the first time. Here's the code:
Code:
Workbooks(UserFormWorkbook).Activate
Range("B4").Select
' Set Do loop to stop when an empty cell is reached.
Do Until IsEmpty(ActiveCell)
Set C = ActiveCell
If C.EntireRow.Hidden Then ActiveCell.Offset(1, 0).Select
[My code here.....]
Loop
ActiveCell.Offset(1, 0).Select
Loop