lprabhu1107
Board Regular
- Joined
- Mar 10, 2011
- Messages
- 106
Ho experts
I have created a macro for refreshing the pivot table and also to change the snapshot date in the pagefield.(Snapshot date has all the date in the month and i want to select todays date)
Following is the macro
'
ActiveSheet.PivotTables("PivotTable2").PivotCache.Refresh
ActiveSheet.PivotTables("PivotTable2").PivotFields_("Snapshot").PivotFilters = Format(Today, "DD-MMM")
Sheets("Total Pivot").Select
If i run the macro, pivottable gets refreshed but the snapshot date returns an error
I have created a macro for refreshing the pivot table and also to change the snapshot date in the pagefield.(Snapshot date has all the date in the month and i want to select todays date)
Following is the macro
'
ActiveSheet.PivotTables("PivotTable2").PivotCache.Refresh
ActiveSheet.PivotTables("PivotTable2").PivotFields_("Snapshot").PivotFilters = Format(Today, "DD-MMM")
Sheets("Total Pivot").Select
If i run the macro, pivottable gets refreshed but the snapshot date returns an error