Kristensen11
New Member
- Joined
- Jul 17, 2018
- Messages
- 7
Hi all,
ActiveSheet.PivotTables("BuyerOnTime").PivotFields( _
"[Fact_Purchase].[USER_NAME].[USER_NAME]").CurrentPageName = _
"[Fact_Purchase].[USER_NAME].Buyer(i)"
I am trying to make a VBA code, that can change the filter of a Pivottable in a dynamic way.
I made an array to store usernames and now i would like the pivottable to be filtered by the data stored in the array.
The "Buyer(i) is the array.
Is this possible? can anyone help?
Thanks!
ActiveSheet.PivotTables("BuyerOnTime").PivotFields( _
"[Fact_Purchase].[USER_NAME].[USER_NAME]").CurrentPageName = _
"[Fact_Purchase].[USER_NAME].Buyer(i)"
I am trying to make a VBA code, that can change the filter of a Pivottable in a dynamic way.
I made an array to store usernames and now i would like the pivottable to be filtered by the data stored in the array.
The "Buyer(i) is the array.
Is this possible? can anyone help?
Thanks!