View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Roger Govier[_3_] Roger Govier[_3_] is offline
external usenet poster
 
Posts: 2,480
Default Filter a pivot table in a macro

Hi

Perhaps you could group dates by Month and Day, making the earliest date the
first date you require, and the latest date 3 months later.
Exclude the results for date < and Greater tan the relevant dates, and only
select the Months.

--
Regards
Roger Govier



"Jean-Marc P" wrote in message
...
I import a .txt file (separated with ","). There a 3 columns that I'm
interested in: "Part number","Required Date" & "Required quantity". I need
the minimum quantity required for each part, so I created a pivot table
with,
on the left: Req.Date, on top: Part Number & in the middle: min Qty
Required.
NOw when I download that file, i get the info for the 6 previous months
plus
the next year. I only want to show the next 3 months in my pivot table.
How
can I do this ? Even if I sort the data that I get, when I update the
pivot
table, the non-desired dates are still shown.

Thanks again !

Jean-Marc

"Bernie Deitrick" wrote:

Jean-Marc,

Do you have a Pivot Table or a database?

Describe the structure of whichever you have, and we'll go from there.

HTH,
Bernie
MS Excel MVP


"Jean-Marc P" wrote in message
...
Hi,

I download a spreadsheet every week, with one of the fields being a
date. I
need to take out only the dates between the current day & 3 months
later.
When I do a macro, it just won't let me filter the pivottable. How can
I do
this ?

Thanks for your help !