Drop Down List Creating Prices in adjoining box

  • Thread starter Thread starter WoodyAccess
  • Start date Start date
Although just following the link didn't give me the exact info (i had to use
the VLOOKUP Worksheet) I did get the information.

Using in cell D8 the formula

=IF(C8="","",VLOOKUP(C8,Products!$A$2:$C$37,2,FALSE))

I had to add in the co-ordinates $A$2:$C$37 of the table rather than just
writing in (as the website says)

=IF(C8="","",VLOOKUP(C8,Products!,2,FALSE)) this gave the result of #N/A



But I got there eventually. This will be a big help
 
I am creating a list with with adjoining cells that show the food item,
calories, carbs, protein and fat intake. I have tried adapting the tutorial
you have but no luck. Please help!!!
 
The tutorial has 2 columns in the lookup table, and your lookup table
would have 5 columns. In the VLookup formula, you'd refer to the column
that has the data you want.

For example, if Protein is in the 4th column of the lookup table, you'd
use a 4 in the VLookup formula.

=VLOOKUP(B2,FoodTable,4,0)

In the above formula, the food item that you selected is in cell B2, and
the lookup table has been named FoodTable.
 
Thanks, that worked great!!! I have an ever growing list of items for my
drop down list, what is the best wasy to continually update that list?
 
Thanks again!!! Next question, in this sheet I am having a running total for
the daily calorie intake. In the boxes that I have not yet selected an item,
the adjoing boxes that have the calorie, protein, etc show '#N/A'. How do I
have this stay blank when nothing is selected and how do I not let this
affect my running total?
 
You can wrap the VLookup formula with an IF formula. For example:

=IF(B2="","",VLOOKUP(B2,FoodTable,4,0))

Then, if cell B2 is empty, the formula cell will also appear empty.
 
Back
Top