Excel Filter in Pivot cube data
I need help, I want to filter date range of a Pivot table data from cube using begin date and end date field field in excel. I have tried some VBA code but no success.
I have attached sample file from CUBE
Script used
Public Sub MyFilter()
Dim lngStart As Long, lngEnd As Long
lngStart = Range("E1").Value 'assume this is the start date
lngEnd = Range("E2").Value 'assume this is the end date
Range("B4:V4").AutoFilter field:=1, _
Criteria1:=">=" & lngStart, _
Operator:=xlAnd, _
Criteria2:="<=" & lngEnd
End Sub
Note:
kindly help thank you.
Attachment | Size |
---|---|
Sample Data.xlsx | 9.01 KB |
Recent comments
5 years 34 weeks ago
6 years 20 weeks ago
6 years 32 weeks ago
6 years 35 weeks ago
6 years 36 weeks ago
6 years 42 weeks ago
6 years 50 weeks ago
6 years 50 weeks ago
6 years 50 weeks ago
6 years 50 weeks ago