Sub ApplyPivotFilter()
Dim pItem As PivotItem
With ActiveSheet.PivotTables("ActivityEstimatesPivotTable").PivotFields( _
"Status")
For Each pItem In .PivotItems
If (pItem.Value <> "4 - Resolved") And _
(pItem.Value <> "Verified") Then
pItem.Visible = False
End If
Next pItem
End With
End Sub
|