+ Reply to Thread
Results 1 to 5 of 5

Excel 2007 : Pull data from a sheet name referenced by a cell

  1. #1
    Registered User
    Join Date
    02-04-2010
    Location
    North Carolina
    MS-Off Ver
    Excel 2007
    Posts
    52

    Pull data from a sheet name referenced by a cell

    Hey all,
    Here is my setup
    I have a main sheet with several pieces of data. In Cell A2 I have a persons name, we'll call him Kent

    I have other sheet names called "Kent 6 Mo Currency" and "Kent 12 Mo Currency"
    What I am trying to do is: in Cell P2 on the main sheet, I want to reference cell H5 in "Kent 12 Mo Currency" using A2 as a variable.
    I've tried :
    =INDIRECT(CONCATENATE(A2," 12 Mo Currency!H5"))
    =INDIRECT(A2&" 12 Mo Currency!H5")
    They both return #REF

    I am trying to work it this way so that when I copy the formula to the next person, i won't have the pain of typing "=" then selecting the sheet name and cell


    I would like the format to become cell A2 would be "Kent, Clark" and the formula would pull from sheet "Clark 12 Mo Currency"

    Can anyone offer suggestions?
    Last edited by usafmeinweg; 04-01-2010 at 04:41 PM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Pull data from a sheet name referenced by a cell

    Try:

    =INDIRECT("'"A2&" 12 Mo Currency'!H5")

    if A2 contains Kent, Clark

    =INDIRECT("'"&TRIM(MID(A2,FIND(","A2)+1,255))&" 12 Mo Currency'!H5")
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    02-04-2010
    Location
    North Carolina
    MS-Off Ver
    Excel 2007
    Posts
    52

    Re: Pull data from a sheet name referenced by a cell

    That didn't work, however i did get this to work
    =INDIRECT(CONCATENATE("'",A2," 12 Mo Currency'!H5"))
    Thanks

    anyone know how I can now make it so the persons name can be Kent, Clark and it reference Sheet "Kent 12 Mo Currency"?

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Pull data from a sheet name referenced by a cell

    Quote Originally Posted by usafmeinweg View Post
    That didn't work, however i did get this to work
    =INDIRECT(CONCATENATE("'",A2," 12 Mo Currency'!H5"))
    Thanks

    anyone know how I can now make it so the persons name can be Kent, Clark and it reference Sheet "Kent 12 Mo Currency"?
    Sorry forgot an &

    should've been: =INDIRECT("'"&A2&" 12 Mo Currency'!H5")

    for your next question:

    =INDIRECT("'"&LEFT(A2,FIND(",",A2)-1)&" 12 Mo Currency'!H5")

  5. #5
    Registered User
    Join Date
    02-04-2010
    Location
    North Carolina
    MS-Off Ver
    Excel 2007
    Posts
    52

    Re: Pull data from a sheet name referenced by a cell

    You are the man. Thanks much

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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