I created a Macro button that sorts columns specifically to print out at a report. This works great until I insert/add rows to the columns i am sorting: the range the macro was set up for does not match the # of rows in the column.
Example:
Orginal macro sorting range is: ActiveSheet.Range("$A$3:$V$100") where row 101 is blank, and row 102 is a subtotal. I add 2 rows, now I want my sorting range to be: ActiveSheet.Range("$A$3:$V$102") where row 103 is blank, and row 104 is a subtotal. This does not automatically update as I wrote the macro from the "Developer" tab "record macro" function, the range stays: ActiveSheet.Range("$A$3:$V$100").
How does one have excel automatically update the range?
Bookmarks