+ Reply to Thread
Results 1 to 11 of 11

Look Up value range formula

  1. #1
    Registered User
    Join Date
    02-19-2016
    Location
    USA
    MS-Off Ver
    2013
    Posts
    27

    Look Up value range formula

    I am stumped and am not sure if a formula or macro is the solution.

    If a user enters a value in cell A1 (ex. $1150)
    I want Cell A2 to read this quantity and apply the appropriate value from a separate data table heading that is rounded up.

    If the data table does not have a value for $1150 it applies the information from the header reading $1200.

    Can someone give me some guidance here?
    Attached Files Attached Files
    Last edited by NSchipper; 02-19-2016 at 02:35 PM. Reason: Workbook Adition

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Formula Stumped

    Welcome to the board.

    Please take a few minutes to read the forum rules, and then amend your thread title accordingly.

    Thanks.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    02-19-2016
    Location
    USA
    MS-Off Ver
    2013
    Posts
    27

    Re: Look Up value range formula

    Upon further review, an INDEX or MATCH function may work here, but I am unsure on how to write it.

    Cell A1 - $1150

    Then a data set is indexed for this column and the value from a specific row in that data set is returned.

    The challenge is if the value is changed that the returning value changes with it.

    Any thoughts?

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Look Up value range formula

    Perhaps you could post a workbook with an example and desired results.

  5. #5
    Registered User
    Join Date
    02-19-2016
    Location
    USA
    MS-Off Ver
    2013
    Posts
    27

    Re: Look Up value range formula

    Workbook Uploaded, for reference cell C9 needs to search the data set array L7:AV7 for the value placed by the user in cell C5 and return the appropriate result from that column/row intersection.

  6. #6
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP, 2007, 2024
    Posts
    16,410

    Re: Look Up value range formula

    You have used the VLOOKUP() function for horizontally oriented data. In this case, you would use the HLOOKUP() function (https://support.office.com/en-us/art...__toc309306714 ). Or use the MATCH() function as I explain in the other thread (http://www.excelforum.com/showthread...40#post4321440 )
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  7. #7
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Look Up value range formula

    After you unmerge all of the merged cells, in C9,

    =HLOOKUP(C5, L7:AV9, 3)

  8. #8
    Registered User
    Join Date
    02-19-2016
    Location
    USA
    MS-Off Ver
    2013
    Posts
    27

    Re: Look Up value range formula

    that works, is there a way to factor in rounding up vs. down? for example, if the user enters $1175 can the sheet reference the value for $1250?

  9. #9
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP, 2007, 2024
    Posts
    16,410

    Re: Look Up value range formula

    If the data were sorted in descending order, you could simply use the MATCH() function with the third argument set to -1.

    As it is, you can still use the MATCH() function (third argument set to 1), then add one to the function's result. =MATCH($C$5,$L$7:$AV$9,1)+1 --> INDEX(l10:av10,match result).

  10. #10
    Registered User
    Join Date
    02-19-2016
    Location
    USA
    MS-Off Ver
    2013
    Posts
    27

    Re: Look Up value range formula

    Mr. Shorty/shg - if I use the HLOOKUP function, is there a way to search for a rounded up data set? I do not need a rounded up result (I can handle that through formatting). The data set starts at $1000 then moves to $1250.

    If a user enters $1100 can this be directed to the next value UP ex. 1250 as opposed to referencing the lowest total ex. $1000?

  11. #11
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP, 2007, 2024
    Posts
    16,410

    Re: Look Up value range formula

    Did you look at using the MATCH() function (coupled with the INDEX() function) as I explained? If I am understanding what you want, that should work just fine.

+ 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. IF THEN formula stumped
    By tig1142 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 12-30-2014, 03:04 AM
  2. Stumped on Sum/CountIF Formula
    By abaibai in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-28-2013, 03:04 PM
  3. [SOLVED] Stumped on an IF Formula
    By studiostustar in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 10-17-2012, 08:13 PM
  4. [SOLVED] Stumped with Formula Array returning cell adjacent to formula dataset
    By Giles_Silver in forum Excel General
    Replies: 5
    Last Post: 06-04-2012, 12:18 AM
  5. Excel formula - stumped!
    By jamdav666 in forum Excel General
    Replies: 2
    Last Post: 03-22-2012, 11:51 AM
  6. Stumped on Formula
    By Jessamynhp in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-19-2005, 06:05 PM
  7. [SOLVED] Completely stumped for formula
    By kirbster1973 in forum Excel General
    Replies: 3
    Last Post: 05-26-2005, 05:15 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