Search code examples
excelpivot-chart

How to change the data source of an Excel Pivot Chart?


I'm trying to reuse an Excel Pivot Chart to make similar charts from others Pivot Tables.
Suppose I make a Pivot Chart A from a Pivot Table A and customize its colours and formats. After that, suppose I need to make a second Pivot Chart B from a Pivot Table B with the same characteristics from Pivot Chart A. As suggest by @teylyn and @Jon Peltier in their answers, I made different Pivot Tables from the same dataset to do each Pivot Chart.

  • Example dataset
blood   height  weight
A       58      115
A       59      117
B       60      120
AB      61      123
O       62      126
A       63      129
AB      64      132
B       65      135
O       66      139
AB      67      142
A       68      146
B       69      150
AB      70      154
AB      71      159
B       72      164
  • Pivot Tables

Pivot Tables

  • Pivot Chart A

Pivot Chart A

Now suppose I want to recycle this Pivot Chart A copying, pasting and changing its datasource (initially Pivot Table A) to the Pivot Table B. But when I right click into the copied chart and selecting the option Select datasourcethe data range is locked and I can't change its reference cells to the Pivot Table B.

So, is there a way to change the datasource from the copy of the Pivot chart A to the Pivot Table B? Thanks in advance!


Solution

  • To change the data source of a pivot chart, you will have to break the link between the chart and the pivot table. How you can do this is described in the below link:

    https://www.extendoffice.com/documents/excel/2710-excel-pivot-chart-change-data-source-legends.html