praneetbvb
New member
- Joined
- Oct 3, 2012
- Messages
- 1
- Reaction score
- 0
- Points
- 0
Hi,
I am currently using the following code below in the macros for filtering out a certain set of activities in fields LVL to be "0"
Dim PI As PivotItem
With ActiveSheet.PivotTables("PivotTable1").PivotFields("Lvl")
.PivotItems("0").Visible = True
For Each PI In .PivotItems
If PI.Name <> "0" Then
PI.Visible = False
End If
Next PI
End With
I now wish to filter lvl activities with pivot items " 0" and "1" as well.
but, the "1" activities might not be present all the time
I tried my best and could not......can somebody help me in editing the code for me??
I am currently using the following code below in the macros for filtering out a certain set of activities in fields LVL to be "0"
Dim PI As PivotItem
With ActiveSheet.PivotTables("PivotTable1").PivotFields("Lvl")
.PivotItems("0").Visible = True
For Each PI In .PivotItems
If PI.Name <> "0" Then
PI.Visible = False
End If
Next PI
End With
I now wish to filter lvl activities with pivot items " 0" and "1" as well.
but, the "1" activities might not be present all the time
I tried my best and could not......can somebody help me in editing the code for me??