MS Excel: Refresh multiple pivot tables with a button in Excel 2003/XP/2000/97
See solution in other versions of Excel:
Question: In Microsoft Excel 2003/XP/2000/97, is it possible to create a button that will refresh/update multiple pivot tables?
Answer: Yes, you can refresh multiple pivot tables with a button. To do this:
Under the View menu, select Toolbars > Forms.
Create a button in your spreadsheet using the Forms toolbar. To do this, click on the button icon (currently highlighted in picture below) and click on your spreadsheet where you would like the button to appear.
After creating the button, the Assign Macro window should appear. Click on the "New" button.
Then paste in similar code as below in the Button_Click event:
Sheets("Sheet1").Select ActiveSheet.PivotTables("PivotTable1").RefreshTable Sheets("Sheet2").Select ActiveSheet.PivotTables("PivotTable2").RefreshTable
You will need to replace the Sheet1 and Sheet2 with the names of your sheets and PivotTable1 and PivotTable2 with the names of your pivot tables.
To find out the name of a pivot table, right-click on the pivot table and select Table Options.