@John Korchok Here is the code
Private Sub CommandButton1_Click()
Dim wks As Worksheet
Dim pvt As PivotTable
For Each wks In ThisWorkbook.Worksheets
For Each pvt In wks.PivotTables
pvt.RefreshTable
Next pvt
Next wks
End Sub
Private Sub Contractor_Change()
End Sub
Private Sub Refresh_Click()
End Sub
Private Sub Worksheet_PivotTableUpdate(ByVal Target As PivotTable)
Dim rng As Range
Dim wks As Worksheet
Set wks = Sheets("Contractor")
Set rng = wks.Range("A4")
ComboBox1.List = wks.Range(rng.Address, rng.End(xlDown).Address).Value
End Sub
Private Sub ComboBox1_Change()
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Dim objPT As PivotTable, strPitem As String
Dim x As Integer
'Set String equal to ComboBox
strPitem = ComboBox1.Text
With ActiveSheet
Set objPT = .PivotTables(1)
' specify with field
With objPT.PivotFields("Contractor")
.AutoSort xlManual, "Contractor"
'loop through specified field's items & hide them all
For x = 0 To .PivotItems.Count
On Error Resume Next 'error trap in case of no data
If .PivotItems(x).Name = strPitem Then
.PivotItems(strPitem).Visible = True
Else
.PivotItems(x).Visible = False
End If
Next x
On Error GoTo 0
End With
End With
Application.DisplayAlerts = True
Application.ScreenUpdating = True
End Sub