I have been struggling to create a pivot table using the following piece of VBA code, but I cannot find the error. I assigned a watch window to PT2, and I noticed after I set PT2 equal to the PivotCache, PTCache2, PT2 still appears with a value of nothing. The With Block does not work because VBA thinks PT2 is an empty object. I am pulling data from a table, GroupDetects, on another sheet, Detects. I am using Excel 2016.
PT2 Watch Window.png![]()
Please Login or Register to view this content.
Bookmarks