+ Reply to Thread
Results 1 to 2 of 2

Changing named range reference depending on a cell's content

  1. #1
    Registered User
    Join Date
    12-11-2003
    Posts
    14

    Changing named range reference depending on a cell's content

    Where to start?!

    I've got the following formula pulling data in from a second spreadsheet within the same workbook:

    =IF($I$7="MICH",INDEX(MICH,MATCH($D7,LOB,0),MATCH($F$5,Month,0)),0)

    We have 8 different locations ("MICH" being one of them) that we need to be able to access. I can write a nested IF formula that looks at cell I7 (that contains a list of all 8 locations) and, depending on I7's content, brings back the desired values.

    I was hoping someone in the forum could help me write a simpler formula that would not have 7 IF statements embedded in it.

    Any help will be greatly appreciated.

    Thanks,
    Cristo
    Last edited by cparaske; 07-29-2005 at 02:06 PM.

  2. #2
    Registered User
    Join Date
    12-11-2003
    Posts
    14
    If anyone has a similar question, the best way to approach it is with the following formula:
    =INDEX(INDIRECT($I$7),MATCH($D7,LOB,0),MATCH($F$5, Month,0))

    INDIRECT looks at I7 and uses it as the named range (since this is the place it occupies in the INDEX statement). There will be an error if I7 does not equal a named range, so you can limit input by having a list (through data validation)

+ 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