View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Peo Sjoblom Peo Sjoblom is offline
external usenet poster
 
Posts: 3,268
Default I need to use a lookup function in an if formula.

=IF(A2=1,LOOKUP(A3,{1,4,5,6,7,8,10,12,14,16,18,20, 22,24,30,36},{1.08,1.23,1.45,1.62,2,2.46,2.85,4.24 ,4.7,5.25,5.8,6.3,9.55,11.45}),IF(A2=2,"B",
IF(A2=3,"C",IF(A2=4,"D","F"))))

I assume you will replace B, C etc with other versions of the formula, make
sure you don't have quotations like "lookup(etc)"

Another way would be to use


=CHOOSE(A2,LOOKUP(A3,{1,4,5,6,7,8,10,12,14,16,18,2 0,22,24,30,36},{1.08,1.23,1.45,1.62,2,2.46,2.85,4. 24,4.7,5.25,5.8,6.3,9.55,11.45}),"B","C","D")

and of course replace the same way if necessary, it's a bit shorter



--
Regards,

Peo Sjoblom



"Excluxe" wrote in message
...
Creating a cost estimate sheet. I have five parameters and each one has
16
parameters. I can use lookup
=LOOKUP(A3,{1,4,5,6,7,8,10,12,14,16,18,20,22,24,30 ,36},{1.08,1.23,1.45,1.62,2,2.46,2.85,4.24,4.7,5.2 5,5.8,6.3,9.55,11.45"})
for one but this formula has five versions each with different pricing.
therefore I am trying to make an if formula something like
=IF(A2=1,"=LOOKUP(A3,{1,4,5,6,7,8,10,12,14,16,18,2 0,22,24,30,36},{1.08,1.23,1.45,1.62,2,2.46,2.85,4. 24,4.7,5.25,5.8,6.3,9.55,11.45})",IF(A2=2,"B",
IF(A2=3,"C",IF(A2=4,"D","F")))) Problem though is it takes the answer as
text
and not another formula ideas solutions or am overloading the program.