View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
StephanieH StephanieH is offline
external usenet poster
 
Posts: 95
Default Dynamic Pivot Item Selection

The folliwing works to no longer show specific fields. How can I rework this
to show all January dates (the specifics will vary) and not show any other
months. I'll be appending additional dates daily, but want the end user to
easily select only the month they want to review.

With ActiveSheet.PivotTables("PivotTable1").PivotFields ("Date")
.PivotItems("1/7/2009").Visible = False
.PivotItems("1/8/2009").Visible = False
.PivotItems("1/9/2009").Visible = False
.PivotItems("1/10/2009").Visible = False
.PivotItems("1/12/2009").Visible = False
.PivotItems("1/13/2009").Visible = False
.PivotItems("1/14/2009").Visible = False
.PivotItems("1/15/2009").Visible = False
.PivotItems("1/16/2009").Visible = False
.PivotItems("1/17/2009").Visible = False

End With