0

This is my Google Sheet.

I have a number of "shopping" cells formatted to have a dropdown list of products/words using the (right-click) "data validation" function.

I have another cell I want to come up with a total price of all the products chosen from the various "shopping" cells, given each product/word has a defined number value/price.

e.g.

cell 1 chooses "widget1"
cell 2 chooses "widget4"
cell 3 chooses "widget7"

widget1 costs 10
widget4 costs 13
widget7 costs 25

Finally, I want a total price cell to show the total price of all the products chosen.

1
  • can you allow editing? Done
    – Pete
    Commented Mar 2, 2019 at 4:57

1 Answer 1

1
={"Price";
 ARRAYFORMULA(IF(LEN(A8:A),
 IFERROR(VLOOKUP(A8:A, E2:F4, 2, 0), 0)+
 IFERROR(VLOOKUP(B8:B, G2:H4, 2, 0), 0)+
 IFERROR(VLOOKUP(C8:C, I2:J4, 2, 0), 0), ))}

o

2
  • @MARKMYANSWER what does LEN mean?
    – ahorn
    Commented Mar 3, 2019 at 19:37
  • @ahorn LEN counts characters in given cell/range so it's kinda equivalent to IF(A8:A<>"",
    – user0
    Commented Mar 3, 2019 at 19:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.