Almost have it just need a little help to complete

  • Thread starter Thread starter HandiMann
  • Start date Start date
H

HandiMann

I currently have this formula that is working.
=VLOOKUP(A1,Sheet1!A2:E39,5,0) I would like to add to formula to chang
the 5, into 4 or 3 or 2 based on imput in another cell.
Is this possible?

Any help greatly appreciated
 
Hi Handimann!

Here's an Example:
=VLOOKUP(A1,Sheet1!A2:E39,IF(B1="two",2,IF(B1="three",3,IF(B1="four",4
,5))),0)

But briefly, all you need to to replace the column number with any
formula or function that returns a number.
--
Regards
Norman Harker MVP (Excel)
Sydney, Australia
(e-mail address removed)
Excel and Word Function Lists (Classifications, Syntax and Arguments)
available free to good homes.
 
Hi Handimann,

In addition to Normans fine reponse, you can also simply
use a cell reference.

Biff
 
If, for example, the "other cell" is B1, just use it in place of the "5" in
the formula.
=VLOOKUP(A1,Sheet1!A2:E39,B1,0)
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================


I currently have this formula that is working.
=VLOOKUP(A1,Sheet1!A2:E39,5,0) I would like to add to formula to change
the 5, into 4 or 3 or 2 based on imput in another cell.
Is this possible?

Any help greatly appreciated.
 
I must be making a mistake somewhere here is my formula but i'm gettin
a N/A error result.
=VLOOKUP($A$1,$AD$7:$AG$44,IF($P$1="Winter",2,IF($P$1="Summer",3,IF($P$1="May/October",4,0))))

Can someone tell me if this formula will work or what's wrong wit
it?:confused
 
Thanks to everyone who assisted me with this and I hope it can assist
other viewers. I got it to work by adding ,0 before the last)

Once again thanks. :)
 
Back
Top