I am very new to writing/recording macros. I have code that works for sorting data in a worksheet. I recorded a macro, and then copied the code into my other macro in VBA. However, I want to be able to run the macro on any worksheet. When I recorded the macro, it identifies the specific active worksheet I was working in.
How do I change the following code so that I can use this macro on any worksheet that I open?
I also want to change the range I sort to capture however many lines of data the new worksheet may have. It may have 4000 rows, it may have 6000 rows. How do I change that?Please Login or Register to view this content.
Thank you!
Bookmarks