+ Reply to Thread
Results 1 to 4 of 4

Index Function is out of range

  1. #1
    Registered User
    Join Date
    09-20-2022
    Location
    Philippines
    MS-Off Ver
    2017
    Posts
    2

    Index Function is out of range

    Hey Folks! I'm new here and i might need some help. This is on google sheets!

    Capture.PNG


    Formula: =INDEX(HH!$C$5:$FE$10,MATCH(J$9,HH!$B$5:$B,0),MATCH($A10,HH!$C$2:$FE$2,0))

    the #NUM! error happens when I drag down the equation. I want to get all the data from HH and HB but im getting this error: Function INDEX parameter 2 value 7 is out of range.


    Thank you!

    Attached is the excel file.
    DUMMY OF OOS & LSW.xlsx
    Last edited by bbbrohm; 09-21-2022 at 01:09 AM.

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Index Function is out of range

    I dont use "sheets" that often, but it looks to me like you need to "end" the range in the 1st MATCH.....

    =INDEX(HH!$C$5:$FE$10,MATCH(J$9,HH!$B$5:$B,0),MATCH($A10,HH!$C$2:$FE$2,0))
    mabye =INDEX(HH!$C$5:$FE$10,MATCH(J$9,HH!$B$5:$B10,0),MATCH($A10,HH!$C$2:$FE$2,0))

    in your excel sheet, normally the INDEX range spans both MATCH ranges, but yours looks all out of wack?

    =
    INDEX(HH!$C$4:$FE$9,
    MATCH(D$9,HH!$B$4:$B270,0),
    MATCH($A13,HH!$C$2:$FE$2,0))

    Your INDEX (where the answer comes from) is C4:FE9
    but you are getting your row and column intercept from B4:B27 and C2:FE2

    The col ranges looks OK, but the ROW range looks way too long?
    Last edited by FDibbins; 09-21-2022 at 12:01 AM.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    09-20-2022
    Location
    Philippines
    MS-Off Ver
    2017
    Posts
    2

    Re: Index Function is out of range

    Quote Originally Posted by FDibbins View Post
    I dont use "sheets" that often, but it looks to me like you need to "end" the range in the 1st MATCH.....

    =INDEX(HH!$C$5:$FE$10,MATCH(J$9,HH!$B$5:$B,0),MATCH($A10,HH!$C$2:$FE$2,0))
    mabye =INDEX(HH!$C$5:$FE$10,MATCH(J$9,HH!$B$5:$B10,0),MATCH($A10,HH!$C$2:$FE$2,0))

    in your excel sheet, normally the INDEX range spans both MATCH ranges, but yours looks all out of wack?

    =
    INDEX(HH!$C$4:$FE$9,
    MATCH(D$9,HH!$B$4:$B270,0),
    MATCH($A13,HH!$C$2:$FE$2,0))

    Your INDEX (where the answer comes from) is C4:FE9
    but you are getting your row and column intercept from B4:B27 and C2:FE2

    The col ranges looks OK, but the ROW range looks way too long?
    Thank you so much Sir! It's working!

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Index Function is out of range

    Happy to help

+ 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. Replies: 6
    Last Post: 10-29-2021, 05:52 PM
  2. Index and Match function- how to set the range
    By Eric Tsang in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-10-2016, 06:06 PM
  3. [SOLVED] Help with Index function to find range of cells
    By Bretyuin in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 02-24-2016, 05:58 AM
  4. Help using named range with index function
    By mpjennings25 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 08-08-2013, 04:09 PM
  5. Help using named range with index function
    By mpjennings25 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-08-2013, 03:48 PM
  6. [SOLVED] Index Function to search from a range
    By seanyeap in forum Excel Formulas & Functions
    Replies: 14
    Last Post: 10-22-2012, 08:41 PM
  7. using the Range function with index values
    By CovePark in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-10-2008, 01:30 PM

Tags for this Thread

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