View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
J.W. Aldridge J.W. Aldridge is offline
external usenet poster
 
Posts: 425
Default Pivot Table Code - Simple Code Fix?

For an expert, this should be a simple fix.....

(at least I assume that it is....)

The following code works, but only for one or two pivot tables on the
worksheet. I have about 12 pivot tables on the same worksheet and I
need them all to refer to A1 for the source data.

What ammendments are needed?




Sub Test()

ActiveSheet.PivotTables(1).SourceData =
Application.ConvertFormula([a1], xlA1, xlR1C1)

End Sub




Thanx