Search code examples
google-sheetsdrop-down-menuoffset

Using OFFSET on selections in a Dropdown Menu


Goal: I'm trying to make a spreadsheet to help someone estimate the price of the mechanical systems they're designing. They can use dropdown menus to add parts.

Problem: When selecting a part from the dropdown menu, I'd like the part's price to show up in a cell to the right of the dropdown menu.

See example spreadsheet here

Currently, a list of all parts exists in the sheet and works with the dropdown menu. The price for each part is listed two columns to the right. So I guess I need a formula that points to the selected part, and then returns the value two cells to the right?

I tried using OFFSET for this, but couldn't get it to look specifically at the chosen contents in the dropdown menu.

The range of cells containing the parts in this sample sheet is C57:C60. The range containing price is E57:E60. I'm totally new to Google Sheets, so I apologize if my question is convoluted.


Solution

  • You can use VLOOKUP or XLOOKUP:

    =XLOOKUP(B14,C$57:C,E$57:E,,0)
    

    enter image description here