Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,814
Default remove rows from Pivot Table

I have created a Pivot Table with multiple rows of data for each date.
However, I would like to automate so that only the last 2 days of data is
visible. I am able to get the last 2 days showing but can't seem to automate
removing all the rest of the dates.

vD = FormatDateTime(Now() , 2)
vD1 = FormatDateTime(Now() - 1, 2)

With ActiveSheet.PivotTables("PivotTable2").PivotFields ("Day")
.PivotItems(vD).Visible = True
.PivotItems(vD1).Visible = True
End With
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel 2002:How to remove sub total rows in Pivot Table ? Mr. Low Excel Discussion (Misc queries) 2 April 3rd 08 03:32 PM
Pivot table - remove worksheet Greg Excel Worksheet Functions 3 March 23rd 07 06:10 AM
Can you remove duplicates from Pivot Table? Mississauga99 Excel Discussion (Misc queries) 2 October 24th 06 04:39 PM
How to remove the row totals in pivot table? Ai_Jun_Zhang[_16_] Excel Programming 0 November 28th 05 08:25 PM
how to remove "(All)" in a pivot table using VBA Excel Discussion (Misc queries) 1 March 10th 05 01:34 PM


All times are GMT +1. The time now is 07:32 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"