universal code
..CreatePivotTable
alone means nothing, there's probably a "with" few lines before,
refering to which object we add a pivot table
then, you can change it, example...
With ActiveWorkbook.PivotCaches.Add(SourceType:=xlExter nal)
' stuff
.CreatePivotTable
'stuff
end with
this ActiveWorkbook means... the active workbook, so not one book but
anyone one (the active one)...
|