Seeting up repetitive code
I want to repeat this code:
ActiveSheet.PivotTables("PivotTable1").PivotFields ("Month").CurrentPage =
in multiple macros...how would I do it? This is my thought thus far but I'm
not sure about the syntax:
Dim repeat As String
repeat =
ActiveSheet.PivotTables("PivotTable1").PivotFields ("Month").CurrentPage = _
If Range("T6").Value = "2"
repeat&"January_2006"
end if
If Range("T6").Value = "3"
repeat&"February_2006"
end if
etc. etc. - any suggestions?
|