Mega Code Archive
Categories
/
VisualBasic Script
/
Excel
PivotTables Collection
Sub AddTable() Dim pvc As PivotCache Dim pvt As PivotTable Set pvc = ActiveWorkbook.PivotCaches(1) Set pvt = ActiveSheet.PivotTables.Add(PivotCache:=pvc, TableDestination:=Range("A3")) End Sub