Thread: If and Then
View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Duke Carey Duke Carey is offline
external usenet poster
 
Posts: 1,081
Default If and Then

Build a 2 column table with the categories listed in the first column, the
associated fruit in the second column. Let's say this data is in cells D1:E20

You're going to put 5 in cell A1, and you want the associated fruit to
appear in B1

The formula in B1 should be

=VLOOKUP(A1,D1:E20,2,FALSE)



"J" wrote:

An example, I have 20 categories, each category is label with a fruit. So if
i put in one cell category 5, and category 5 is associated with apple, the
cell with the formula should automatically be filled in with the word "apple".

Does this make sense?


"Duke Carey" wrote:

Go to Excel 2007 which allows many more levels

Or, explain what you want to do. It's usually better handled by VLOOKUP or
SUMPRODUCT or the like. Somebody here can guide you if you provide the
background info


"J" wrote:

Does someone know how to increase the levels of nesting that will be allowed
in excel? Currently it's 8 levels.