jmac001
asked on
Deleting rows in a table
Hello Experts,
I am trying to delete information in a table once it has been filtered.
All the visible information that appears in the table after it was filtered has to be deleted (except for the header).
I used the following code:
Sheets("Initiative Summary").ListObjects("Ini tiativeTbl ").listCol umns("Func tional Area").databodyrange.speci alcells(xl CellTypeVi sible).Del ete
The code works fine unless the first item in the table is invisible. In this case it deletes the entire table including the header.
Could you please help me fix this?
Thanks
I am trying to delete information in a table once it has been filtered.
All the visible information that appears in the table after it was filtered has to be deleted (except for the header).
I used the following code:
Sheets("Initiative Summary").ListObjects("Ini
The code works fine unless the first item in the table is invisible. In this case it deletes the entire table including the header.
Could you please help me fix this?
Thanks
ASKER
Angelp1ay, it has to be a macro to automatically perform these operations across multiple worksheets.
Thanks
Thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
- Select the top left data cell to be deleted
- Hit Shift+Ctrl+Down
- Hit Ctrl+-
- Select entire row
You will then see the unfiltered results minus the rows you've just deleted.
Edit: To quickly get to the top left hit Ctrl+Up,Left (possibly a few times if you have empty cells) or alternatively Ctrl+Home but I typically find my hand over the arrow keys when I'm using Excel.