Hi! I'm a Noob with VBA, but I've been trying to automate some processes at work. We have an excel file that contains some 70k records, which we download every day. However, we only need records that don't have a cancelled or completed status (Statuses are text in a column). When I manually autofilter to de-include those statuses, I end up with about 6k records of usable data, which is fine, but i wrote a macro to automatically filter the file for those cancelled or completed statuses, select the rows, and delete them. The end result looks about right, but the file takes MUCH longer to open and interact with than the 5k records could be responsible for. Also, when I ask the Immediate window in VBA for a Used Range count, it still includes the deleted records. I've enclosed my code and I hope I'm clear about the trouble.
(The Rows still show Blue after the Macro runs, but if I manually Select and RightClick->Delete the rows in question, they go away permanent-like.)
Any help you can provide would be simply neato! Thanks!Please Login or Register to view this content.
Bookmarks