LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default VBA help an easy question

This is probably an easy one but I cannot figure it out. I have a pivot
table that displays data by month. What I want to do is automatically
unselect the last month in the list, so if I refresh my table in the middle
of a month it will not show the current month. In my searching the group for
this answer I was able to find some code that automatically selects all items
within the PivotItem. Which will be useful the following month to ensure I
get all months but the current month. What I need is the code to unselect
the last month in the list. The code I was trying to modify to tell it to
unselect the last month is:

With ActiveSheet.PivotTables("PivotTable2").PivotFields ("Month")
.PivotItems(200607).Visible = False

What do I need to have in place of the (200607) to have it use the last
month in the list.


Any help is greatly appreciated and thanks in advanced.

 
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
Easy question M&M[_2_] Excel Discussion (Misc queries) 3 August 11th 07 07:00 AM
Easy Question Bob[_8_] Excel Worksheet Functions 9 July 14th 07 03:50 PM
An easy question... Maybe? Lydon Bergin Excel Programming 1 January 25th 06 05:09 PM
Easy Question dok112[_40_] Excel Programming 2 July 20th 05 11:48 PM
new user with easy question? not easy for me speakeztruth New Users to Excel 5 June 3rd 05 09:40 PM


All times are GMT +1. The time now is 11:55 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"