+ Reply to Thread
Results 1 to 10 of 10

Automatically Refresh Pivot Table with new date

  1. #1
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Arrow Automatically Refresh Pivot Table with new date

    Hello Guys,

    I have a pivot table based of a massive source data that I update manually. Also, whenever I add a new date to the source data, I would like this new date to be added “by default” to my pivot table when refreshed. I Think I need a macro for that, but I’m trying to find a simple way to do it.

    Basically, I have 10 pivot tables set up based of my source data, and I don’t want to go to each and every filter I set up for those tables and tick the new date in the filter so it can be taken into account.

    Please if I’m not that clear, feel free to ask me more details.

    Thank you guys

    I'm on Excel 07
    Last edited by meyero90; 08-04-2010 at 08:43 AM.
    If I helped, Don't forget to add to my reputation (click on the little scale)
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)

  2. #2
    Forum Contributor
    Join Date
    07-01-2010
    Location
    United States, Washington DC
    MS-Off Ver
    Excel 2007
    Posts
    116

    Re: Automatically Refresh Pivot Table with new date

    All you need to do is press F9 to refresh the pivot table once new data has been added

  3. #3
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Re: Automatically Refresh Pivot Table with new date

    It doesn't work. Also, I never heard about F9 as a shortcut to refresh pivot table. I know ctlr +alt + F5 (refresh all) or F5 to refresh a specific table....

    I tried your solution by adding dummy data in data source and see what would happen if I hit F5....but didn't work

    Thanks though

  4. #4
    Registered User
    Join Date
    07-15-2010
    Location
    California, United States
    MS-Off Ver
    Excel 2010
    Posts
    45

    Re: Automatically Refresh Pivot Table with new date

    Turn your original data into a table by going to home>styles>format as table.

    Every time new entries are made into the table click on the pivot table and go to the options of the pivottable tools tab and press refresh from the options table in the data group.

  5. #5
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Re: Automatically Refresh Pivot Table with new date

    Ok, excel328, this was my old way of refreshing all pivot tables. But here's the problem, I have filters set up for every pivot table, so when I add the data in source data.......when I refresh, the new data doesn't get picked up in the pivot table. Instead, I have to go and check "Jun-10" in the filter in order to make the new data appear in the pivot table.

    So....Any clues on how to make my life easier

    Thanks again

  6. #6
    Registered User
    Join Date
    07-15-2010
    Location
    California, United States
    MS-Off Ver
    Excel 2010
    Posts
    45

    Re: Automatically Refresh Pivot Table with new date

    There is a sample file here that refreshes pivot tables.
    http://www.contextures.com/PivotSelectDept.zip

  7. #7
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Re: Automatically Refresh Pivot Table with new date

    First off, thanks for your file (PS: I know this sumproduct formula with criteria, but how can it return “TRUE”, “FALSE”, especially if you sumproduct words? could you explain that to me later

    With respect to my problem, you will see that I added a dummy data highlighted in red in the tab “Exposures”, but when I refresh All ctlr+alt F5 (not using the code, and I didn’t try the code yet)…..the new data doesn’t get picked up in the “All Funds” tab. I have to go manually at the Date Filter at the range “AF115” and tick the newly added date.
    Last edited by meyero90; 08-05-2010 at 01:26 PM.

  8. #8
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Re: Automatically Refresh Pivot Table with new date

    Also, How do you run your macro? I inserted a module and copied your code, but nothing!
    Thanks

  9. #9
    Registered User
    Join Date
    07-15-2010
    Location
    California, United States
    MS-Off Ver
    Excel 2010
    Posts
    45

    Re: Automatically Refresh Pivot Table with new date

    Disregard the sample file because it wasn't that related to the problem. It seems like the dates you are filtering are usually after April 9 2009. Couldn't you set the date filter to filter after this date? Also when you input Jul-50 in your file do you mean July 1950 or July 2050? The date filters should update along with the pivot tables through a refresh if the original table of values are converted into a table.

    As for the sumproduct formula question, the sumproduct yields a number value when used in this form: SUMPRODUCT(--($I$2:$I$11=B2),--($J$2:$J$11=SelDept)).
    However this time the formula was like this =SUMPRODUCT(--($I$2:$I$11=B2),--($J$2:$J$11=SelDept))>0 with the >0 at the end.
    A comparison operator such as a <, >, = was used with the sumproduct output (number value) causing an output of true or false because a comparison is taking place.

  10. #10
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Re: Automatically Refresh Pivot Table with new date

    Wonderful excel328 you made my day man. By Jul-50 I meant 07/31/2050, I rectified this on my source data because it considered as 1950 (it's my mistake ). Also, I applied a filter "is After or Equal" to Jan-07 (the date I usually test my data for) and When I refreshed.....Miracle....It is picking up the new date.....Thanks man and sorry for all the headaches.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1