I am writing a macro that I want to use to select all cells in filtered columns A:P except for the header row, which is always row 1. I've tried using
ActiveCell.SpecialCells(xlLastCell).Select
Range(Selection, Cells(1)).Select
but it selects all the way to A1. What I want is to select from the end to the first visible (based on the filter) cell below A1. I have a feeling the answer is simple, but I can't seem to figure it out. Actually, I thought my code worked the first time I ran it, but every time since then, it has selected all the way to A1. Any ideas?
ActiveCell.SpecialCells(xlLastCell).Select
Range(Selection, Cells(1)).Select
but it selects all the way to A1. What I want is to select from the end to the first visible (based on the filter) cell below A1. I have a feeling the answer is simple, but I can't seem to figure it out. Actually, I thought my code worked the first time I ran it, but every time since then, it has selected all the way to A1. Any ideas?