Hi everyone. I've got a macro that I've been running pretty flawlessly each week for an hours tracking workbook I use.
Basically, I have a Table that contains information I enter daily regarding my projects and the hours associated with them. The table is summarized in a Pivot Table as well, for end-of-the-week reporting in an external application. My macro just copies this sheet, table, and pivot table, renames things for the new week, and lets me repeat the hours accounting info each week.
This macro (code below) has been working well for quite some time, but in the last month or two (I don't remember when) it started throwing up warnings about a list name already existing, and I can either click Yes to use that version of the name, or click No to rename it. This comes up for 4 names of previous lists, all in chronological order (but skipping some lists from previous sheets). It's obvious to me from debugging that it happens when I use the Sheets(1).Copy Before:=Sheets(1) command. What's not obvious is why this should give me 4 list name collisions instead of just one, and why it's picking these 4 specific lists out of many that are in the workbook.
I confess that I made most of this code by just manually doing the steps and recording the macro as I went, so it's entirely possible that I'm doing a million different things very poorly from a programming standpoint. Please don't laugh too badly at my code
Can anyone look at what I did, and more importantly, what I did WRONG? And, provide me some guidance on how I can fix it?![]()
Please Login or Register to view this content.
Thanks in advance for any helpful insights.
-Adam
Bookmarks