Hi,
All I am trying to do is to pick a cell value on a sheet (Invoice #) and force that value to be dispayed in Pivt Table, Here is how I decided to do it;
Sub Macro1()
Dim P As PivotItem
Dim W As Variant
Sheet4.Select
Range("B5").Select
Range("B5").Value = W
P.Value = P
Sheets("Labour Summary All").Select
With ActiveSheet.PivotTables("PivotTable1").PivotFields("WO Number")
.PivotItems("P").Visible = True
End With
End Sub
This does not work and goves me error 91 in, P.Value = P line. Can someone please please help me.
Regards
Kirill
All I am trying to do is to pick a cell value on a sheet (Invoice #) and force that value to be dispayed in Pivt Table, Here is how I decided to do it;
Sub Macro1()
Dim P As PivotItem
Dim W As Variant
Sheet4.Select
Range("B5").Select
Range("B5").Value = W
P.Value = P
Sheets("Labour Summary All").Select
With ActiveSheet.PivotTables("PivotTable1").PivotFields("WO Number")
.PivotItems("P").Visible = True
End With
End Sub
This does not work and goves me error 91 in, P.Value = P line. Can someone please please help me.
Regards
Kirill