Sub PivotTableForExcel2007()
' This code just creates the empty pivot. You need to add pivot filters and fields as required
Dim SourceRange As Range
Set SourceRange = Sheets("Sheet1").Range("A3:N13")
ActiveWorkbook.PivotCaches.Create( _
SourceType:=xlDatabase, _
SourceData:=SourceRange, _
Version:=xlPivotTableVersion12).CreatePivotTable _
TableDestination:="", _
TableName:="", _
DefaultVersion:=xlPivotTableVersion12
End Sub
VBA Outlook KPI Excel Alt+F11 Dashboards Macros Recording Graphs Automation Developer WaterFall Powerpoint Charts Pivot Tables Forecast Charts