View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bill Manville Bill Manville is offline
external usenet poster
 
Posts: 473
Default Pivot Table Question

wrote:
The
problem is, that the macro starts of with a reference to "Count of A".
How do I set this up so that I can simply replace "B" with a new
variable and have it work?


Try replacing

.PivotFields("Count of A")
with
.DataFields(1)
assuming you are only displaying one datafield

Bill Manville
MVP - Microsoft Excel, Oxford, England
No email replies please - reply in newsgroup