I am trying to create a macro that creates a pivot table based on another worksheet. It will create that worksheet and rename that worksheet, but it doesn't create a pivot table. I used the following code, which I got from recording a macro and doing the exact thing I wanted it to do and this is the code that I got. I also noticed that is you remove your data and try to create a new pivot table it always changes the # (ie. Pivot table1, Pivot table2). Could this be messing it up? TIA!
Sub MacroTest()
'
Bookmarks