temerson11
New Member
- Joined
- Jul 31, 2018
- Messages
- 2
I'm trying to hide certain data fields (or cube fields in this situation) with VBA. Here is my current code:
Dim pt As PivotTable, cf As CubeField
Set pt = Sheets("RECAP").PivotTables("Major/SubCat Pivot")
With pt
.ManualUpdate = True
ActiveSheet.PivotTables("Major/SubCat Pivot").CubeFields
cf("Vendor").Orientation = xlHidden
Dim pt As PivotTable, cf As CubeField
Set pt = Sheets("RECAP").PivotTables("Major/SubCat Pivot")
With pt
.ManualUpdate = True
ActiveSheet.PivotTables("Major/SubCat Pivot").CubeFields
cf("Vendor").Orientation = xlHidden