Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a pivot table that I would like to limit to the previous weeks date
range. How can I code something that will filter out all dates other then the previous weeks? The pivot table structure will be rows of employees names, columns of Dates and a count of transactions. In an example for today, I would want a date range of 2/3 - 2/9. Then next week it would list 2/10 - 2/16. Thanks for the help. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Greg, other than unselecting all dates and selecting only the ones you want,
the only way to do this is to add a helper column with a calculation to calculate weeks. Here's an example formula to add to your data set to give you a column listing the previous week in the format of MM/DD/YYYY: =TEXT(A1-7-(WEEKDAY(A1)-1),"MM/DD/YYYY") & " - " & TEXT(A1-WEEKDAY(A1),"MM/DD/YYYY") Be sure to remove all line breaks. Then add the new column as the page field in the pivot table and select the week that you want. Let me know if you need additional help. -- Charles Chickering "A good example is twice the value of good advice." "Greg H." wrote: I have a pivot table that I would like to limit to the previous weeks date range. How can I code something that will filter out all dates other then the previous weeks? The pivot table structure will be rows of employees names, columns of Dates and a count of transactions. In an example for today, I would want a date range of 2/3 - 2/9. Then next week it would list 2/10 - 2/16. Thanks for the help. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Limit Pivot Table by date | Charts and Charting in Excel | |||
Limit access in a pivot table | Excel Worksheet Functions | |||
Pivot table limit | Excel Worksheet Functions | |||
pivot reports - limit report to last 20 dates | Excel Worksheet Functions | |||
pivot help - limit data for last 20 dates | Excel Worksheet Functions |