Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How do I change the date in a pivot table pagefield using VBA
My pivot table shows one day's worth of data. I have multiple
departmenst in the rows, and 3 categories of expenditures in the columns. I use the Page area to show a date. How do I use VBA to change the date to today()-1 (yesterday). Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
How do I change the date in a pivot table pagefield using VBA
I defined the date I want to use w/ dim and then used this code:
Dim pvtdate as date pvtdate = Worksheets("By Trade").Range("d75").Text ActiveSheet.PivotTables("PivotTable1").PivotCache. refresh ActiveSheet.PivotTables("PivotTable1").PivotFields ("DT_TRANS_DATE"). _ CurrentPage = pvtdate st wrote: My pivot table shows one day's worth of data. I have multiple departmenst in the rows, and 3 categories of expenditures in the columns. I use the Page area to show a date. How do I use VBA to change the date to today()-1 (yesterday). Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Pivot Table Change to US Date Format - Why? | Excel Discussion (Misc queries) | |||
DATE FORMAT CHANGE FROM EXCEL WORKSHEET TO PIVOT TABLE | Excel Discussion (Misc queries) | |||
how to change date formating-grouped by month in pivot table | Excel Discussion (Misc queries) | |||
Pivot Table PageField | Excel Programming | |||
How to find the current pagefield of a pivot table? | Excel Programming |