+ Reply to Thread
Results 1 to 5 of 5

Help with formula

  1. #1
    Registered User
    Join Date
    12-29-2006
    Posts
    2

    Help with formula

    Hi,

    Is it possible to use the text in a cell as part of a formula or function in another cell. Say I'm in a sheet called TEST and cells A1, B1, and C1 look like this:

    BLUE
    GREEN
    RED

    and I have several different worksheets, 3 of which are named BLUE, GREEN, and RED. Normally if I wanted to link to the data in cell F5 in one of those sheets, the formula would look like:
    =+'BLUE'!F5

    My question is, is there someway I can use the data in cell A1 of my current sheet to tell the formula to look at sheet BLUE instead of actually typing BLUE or having to click over to that sheet while writing the formula. I know the following formula is invalid but this may help understand what I am trying to do.
    =+'(A1)'!F5 or something along those lines instead of =+'BLUE'!F5

    Thanks for your help!
    Jeff

  2. #2
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    Hi,

    Try the indirect function

    http://www.cpearson.com/excel/indirect.htm

    VBA
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

  3. #3
    Valued Forum Contributor
    Join Date
    03-25-2004
    Location
    Boston, MA US
    Posts
    1,094
    Try,

    =INDIRECT(A1&"!F5")

    HTH,

    Steve

  4. #4
    Registered User
    Join Date
    12-29-2006
    Posts
    2
    Thank you both, that was exactly what I was looking for!

  5. #5
    Forum Contributor
    Join Date
    03-13-2005
    Posts
    6,195
    Quote Originally Posted by arioch10
    Hi,

    Is it possible to use the text in a cell as part of a formula or function in another cell. Say I'm in a sheet called TEST and cells A1, B1, and C1 look like this:

    BLUE
    GREEN
    RED

    and I have several different worksheets, 3 of which are named BLUE, GREEN, and RED. Normally if I wanted to link to the data in cell F5 in one of those sheets, the formula would look like:
    =+'BLUE'!F5

    My question is, is there someway I can use the data in cell A1 of my current sheet to tell the formula to look at sheet BLUE instead of actually typing BLUE or having to click over to that sheet while writing the formula. I know the following formula is invalid but this may help understand what I am trying to do.
    =+'(A1)'!F5 or something along those lines instead of =+'BLUE'!F5

    Thanks for your help!
    Jeff
    .. ..

    of course,

    you need something to change A1 from Blue to Green to Red, rather than use A1 B1 and C1 in your indirect formula.

    ---
    Si fractum non sit, noli id reficere.

+ 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