Hi,
I have a report that takes info from several pivot tables analysing different criterias,
Each will start with the same top two tiers:
Surveying Firm
&
Year-Month-Day.
I'd like to write a macro that will reset the filter based on the contents of E3 and E4
E3 being the Date E4 being the surveying firm.
This is what i have for the Month
I can't work out how i should reference E3 in the code below, i've tried ActiveSheet.Range("E3").Value but it doesn't like it.
Any ideas?
PS. the data is coming from a server connection rather than a table within the spreadsheet if this makes any difference.
Thanks
Ben
I have a report that takes info from several pivot tables analysing different criterias,
Each will start with the same top two tiers:
Surveying Firm
&
Year-Month-Day.
I'd like to write a macro that will reset the filter based on the contents of E3 and E4
E3 being the Date E4 being the surveying firm.
This is what i have for the Month
Code:
' Macro10 Macro
'
ActiveSheet.PivotTables("PivotTable1").PivotFields("[Time].[Year-Month-Day].[Month Name]").ClearAllFilters
ActiveSheet.PivotTables("PivotTable1").PivotFields( _
"[Time].[Year-Month-Day].[Month Name]").VisibleItemsList = Array( _
"[Time].[Year-Month-Day].[Year].&[2010].&[August]")
End Sub
I can't work out how i should reference E3 in the code below, i've tried ActiveSheet.Range("E3").Value but it doesn't like it.
Any ideas?
Code:
"[Time].[Year-Month-Day].[Year].&[2010].&[August]")
PS. the data is coming from a server connection rather than a table within the spreadsheet if this makes any difference.
Thanks
Ben