+ Reply to Thread
Results 1 to 3 of 3

VBA code to go back once drilled down on pivot table

  1. #1
    Registered User
    Join Date
    02-14-2014
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    33

    Question VBA code to go back once drilled down on pivot table

    I have created a dashboard with a number of pivot tables in excel 2007. The users would go to the pivot table and double click on the data and all of the information is revealed in a separate sheet. In order for them to go back they currently click on Ctrl Z where a message box appears asking if you would like to delete the sheet or Cancel to stay on the sheet. Once the User clicks on Delete the sheet is deleted and they go back to the relevant Pivot table. Is there any way in which I can enter some code and a button for them to press at the bottom of the data produced from drilling down on the Pivot to take them back to the appropriate Pivot table.

    Your help in this matter is much appreciated as I am a novice when it comes to VBA code
    Last edited by ZuneidDassu; 07-27-2016 at 08:57 AM.

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,920

    Re: VBA code to go back once drilled down on pivot table

    If you are going to do this by double clicking on the pivot table, then I don't think if can be done. It's sort like invoking the inverse of a go to command: the come from command. In all my years of programming I haven't figured out how to do that one.

    However, if you make a before double click event, you can make this happen. Personally, I am surprised this works. The sheet that contains the pivot table is called Pivot. The code is in the module on that page:
    Please Login or Register  to view this content.
    I mapped the subroutine Recover to CTRL-r. So when you double click, you open up the new sheet. When you click CTRL-R, you are returned to the sheet named Pivot.
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

  3. #3
    Registered User
    Join Date
    02-14-2014
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    33

    Re: VBA code to go back once drilled down on pivot table

    Thanks this has now been closed

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Source data is a drilled down table. Pivot this?
    By kgowett in forum Excel General
    Replies: 2
    Last Post: 06-24-2016, 11:08 AM
  2. Transforming pivot table back to the source table
    By Frile in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-17-2015, 02:34 AM
  3. Pivot Table, use VBA to get use back to record in source data table
    By gr8tday in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-17-2014, 01:30 AM
  4. [SOLVED] VBA to pull back a Name if value of the data is > 0 in the pivot table
    By martystoked in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 10-21-2013, 05:12 PM
  5. sending blanks back from pivot table with GETPIVOTDATA formula
    By HeikEve in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 05-23-2013, 09:55 PM
  6. It's back! Bizarre Pivot Table Problem
    By mblevin in forum Excel General
    Replies: 0
    Last Post: 08-25-2007, 08:51 PM
  7. [SOLVED] Right Click Pivot table -> Wizard -> Back button is disable
    By Ashok in forum Excel General
    Replies: 0
    Last Post: 11-16-2005, 06:15 PM

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