+ Reply to Thread
Results 1 to 5 of 5

GetPivotData & Indirect

  1. #1
    Forum Contributor
    Join Date
    10-14-2011
    Location
    London, England
    MS-Off Ver
    O365
    Posts
    180

    GetPivotData & Indirect

    Hello, last one I promise!

    I've just been playing with GetPivotData and it will do just what I want for a summary sheet. I don't want to have to manually edit hundreds of formulas though so was hoping to use INDIRECT to refer to the sheet names etc so I can just fill these in in a cell.

    I have it half working....

    =GETPIVOTDATA(TEXT(INDIRECT("B5"),"@"),'Question 1'!$F$6,TEXT(INDIRECT("B5"),"@"),"Correct")

    In cell B5 I have the text "QUESTION 1" so would then just change this one column to Question 2, Question 3 etc.

    What I want to do now is replace the sheet name but everything I've tried comes up with #REF.

    How can I refer to cell F6 on the worksheet "Question 1" in this formula from a cell value?

  2. #2
    Forum Contributor
    Join Date
    10-14-2011
    Location
    London, England
    MS-Off Ver
    O365
    Posts
    180

    Re: GetPivotData & Indirect

    Got it, got it, got it. Just had to use INDIRECT without the TEXT

  3. #3
    Forum Guru xlnitwit's Avatar
    Join Date
    06-27-2016
    Location
    London
    MS-Off Ver
    Windows: 2010; Mac: 16.13 (O365)
    Posts
    7,085

    Re: GetPivotData & Indirect

    You should be able to use
    =GETPIVOTDATA(B5,INDIRECT("'"&B5&"'!$F$6"),B5,"Correct")
    Don
    Please remember to mark your thread 'Solved' when appropriate.

  4. #4
    Forum Contributor
    Join Date
    10-14-2011
    Location
    London, England
    MS-Off Ver
    O365
    Posts
    180

    Re: GetPivotData & Indirect

    I kept getting errors until I read somewhere that the TEXT one worked but got there now. Many thanks.

  5. #5
    Forum Guru xlnitwit's Avatar
    Join Date
    06-27-2016
    Location
    London
    MS-Off Ver
    Windows: 2010; Mac: 16.13 (O365)
    Posts
    7,085

    Re: GetPivotData & Indirect

    Sorry, I forgot you need to add quotes for the data field name
    =GETPIVOTDATA(""&B5,INDIRECT("'"&B5&"'!$F$6"),B5,"Correct")

+ 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] GETPIVOTDATA – How to force getpivotdata to accept missing data
    By scottc_00 in forum Excel Formulas & Functions
    Replies: 39
    Last Post: 02-11-2015, 03:23 PM
  2. [SOLVED] INDIRECT Function with multiple sheets - SUMIF, INDIRECT & MATCH
    By DJDRU in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 10-07-2014, 08:42 AM
  3. Sum of indirect sheet names with multiple cells (SUM, INDIRECT,SHEETNAME in cell)
    By a1b2c3d4e5f6g7h8 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 02-12-2013, 08:42 AM
  4. Allow EXCEL INDIRECT(ADDRESS()) and INDIRECT(RANGE()) functions
    By Andy Wiggins in forum Excel Formulas & Functions
    Replies: 18
    Last Post: 09-06-2005, 12:05 PM
  5. Allow EXCEL INDIRECT(ADDRESS()) and INDIRECT(RANGE()) functions
    By Mike Barlow in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 03:05 AM
  6. Allow EXCEL INDIRECT(ADDRESS()) and INDIRECT(RANGE()) functions
    By Mike Barlow in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-05-2005, 11:05 PM
  7. [SOLVED] Allow EXCEL INDIRECT(ADDRESS()) and INDIRECT(RANGE()) functions
    By Mike Barlow in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 07-05-2005, 11:05 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