![]() |
Excel If function alternative
hello
In my spreadsheet, I've been using a nested if function, but now I need to expand it to 12 if statements and since there is a max of 8, basically my formula is this If a1=1, z1, if a1=2, z2, if a1=3, z3 and so on. What other function can I use to do this |
You might try:
=choose(A1,Z1,Z2,Z3,Z4,Z5,Z6,Z7,Z8,Z9,Z10,Z11,Z12) Will that work for you? Ron |
=INDEX(Z1:Z12,MATCH(A1,{1;2;3;4;5;6;7;8;9;10;11;12 },0))
-- Regards, Peo Sjoblom "saborbas" wrote in message ... hello In my spreadsheet, I've been using a nested if function, but now I need to expand it to 12 if statements and since there is a max of 8, basically my formula is this If a1=1, z1, if a1=2, z2, if a1=3, z3 and so on. What other function can I use to do this |
Classic application for the VLOOKUP feature. Put 1 in Y1 and fill down to
Y12........ Then in B1(or whereever), put this formula =VLOOKUP(A1,Y1:Z12,2,FALSE) Vaya con Dios, Chuck, CABGx3 "saborbas" wrote in message ... hello In my spreadsheet, I've been using a nested if function, but now I need to expand it to 12 if statements and since there is a max of 8, basically my formula is this If a1=1, z1, if a1=2, z2, if a1=3, z3 and so on. What other function can I use to do this |
Everyone is guessing as you don't show what you already have. Give us some
help. -- HTH RP (remove nothere from the email address if mailing direct) "CLR" wrote in message ... Classic application for the VLOOKUP feature. Put 1 in Y1 and fill down to Y12........ Then in B1(or whereever), put this formula =VLOOKUP(A1,Y1:Z12,2,FALSE) Vaya con Dios, Chuck, CABGx3 "saborbas" wrote in message ... hello In my spreadsheet, I've been using a nested if function, but now I need to expand it to 12 if statements and since there is a max of 8, basically my formula is this If a1=1, z1, if a1=2, z2, if a1=3, z3 and so on. What other function can I use to do this |
Would this work? This has no error checking.
=INDIRECT("Z" & A1) -- Dana DeLouis Win XP & Office 2003 "saborbas" wrote in message ... hello In my spreadsheet, I've been using a nested if function, but now I need to expand it to 12 if statements and since there is a max of 8, basically my formula is this If a1=1, z1, if a1=2, z2, if a1=3, z3 and so on. What other function can I use to do this |
saborbas wrote:
hello In my spreadsheet, I've been using a nested if function, but now I need to expand it to 12 if statements and since there is a max of 8, basically my formula is this If a1=1, z1, if a1=2, z2, if a1=3, z3 and so on. What other function can I use to do this If A1 = 1,2,3,...,N, then: =INDEX(Z-range,A1) should suffice. |
All times are GMT +1. The time now is 07:14 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com