G
Guest
I have a button that creates a pivot chart and table. The data consists of
0's and 1's. This is the code I am using ...
With ActiveChart.PivotLayout.PivotFields("0")
.Orientation = xlRowField
.Position = 1
End With
With ActiveChart.PivotLayout.PivotFields("0")
.Orientation = xlDataField
.Position = 1
End With
ActiveChart.PivotLayout.PivotFields("0").Caption = "Types of Reports"
The problem is that the first cell has to show "0" for the macro to work.
Our data could start with "1". How do I make the "0" in parenthesis different
so that it grabs the first cell content as the first field for the pivot
chart and table. Help!!
0's and 1's. This is the code I am using ...
With ActiveChart.PivotLayout.PivotFields("0")
.Orientation = xlRowField
.Position = 1
End With
With ActiveChart.PivotLayout.PivotFields("0")
.Orientation = xlDataField
.Position = 1
End With
ActiveChart.PivotLayout.PivotFields("0").Caption = "Types of Reports"
The problem is that the first cell has to show "0" for the macro to work.
Our data could start with "1". How do I make the "0" in parenthesis different
so that it grabs the first cell content as the first field for the pivot
chart and table. Help!!