Home |
Search |
Today's Posts |
#1
|
|||
|
|||
FORMULA
I need to write an if then statement that contains more than 7 nested levels
how do I do that. So far I have: =IF(D375,"3.350",IF(D370,"2.034",IF(D365,"1.152 ",IF(D360,".738",IF(D355,".630",IF(D350,".387", IF(D345,".252",IF(D340,".153",".063")))))))) which works, but soon as I add another IF statement it gives me an error message. I need to add 2 more IF statements for this formula to work.... Thanks |
#2
|
|||
|
|||
Hi, Fran. If you set up a table for your values and use VLOOKUP, you can
easily change the values later in the table without having to update your formula. See: http://www.officearticles.com/excel/...soft_excel.htm ************ Anne Troy www.OfficeArticles.com "Fran" wrote in message ... I need to write an if then statement that contains more than 7 nested levels how do I do that. So far I have: =IF(D375,"3.350",IF(D370,"2.034",IF(D365,"1.152 ",IF(D360,".738",IF(D355,".630",IF(D350,".387", IF(D345,".252",IF(D340,".153",".063")))))))) which works, but soon as I add another IF statement it gives me an error message. I need to add 2 more IF statements for this formula to work.... Thanks |
#3
|
|||
|
|||
Thanks I'll check it out.
"Anne Troy" wrote: Hi, Fran. If you set up a table for your values and use VLOOKUP, you can easily change the values later in the table without having to update your formula. See: http://www.officearticles.com/excel/...soft_excel.htm ************ Anne Troy www.OfficeArticles.com "Fran" wrote in message ... I need to write an if then statement that contains more than 7 nested levels how do I do that. So far I have: =IF(D375,"3.350",IF(D370,"2.034",IF(D365,"1.152 ",IF(D360,".738",IF(D355,".630",IF(D350,".387", IF(D345,".252",IF(D340,".153",".063")))))))) which works, but soon as I add another IF statement it gives me an error message. I need to add 2 more IF statements for this formula to work.... Thanks |
#4
|
|||
|
|||
Fran, I would approach this problem differently. I would make a table on another sheet. Something like this on say Sheet1 A1:B10: Column A Column B 75 3.350 70 2.034 and so on.................... Then use a formula like this IF(D3<"",VLOOKUP(D3,Sheet1!A1:B10,2,FALSE),0) Then you can have as many choices as you need and if in the future the values change, you just have to change the little table not all those formulas. HTH -- Casey ------------------------------------------------------------------------ Casey's Profile: http://www.excelforum.com/member.php...fo&userid=4545 View this thread: http://www.excelforum.com/showthread...hreadid=475915 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
IF formula? | Excel Worksheet Functions | |||
writing a formula for a colored value | New Users to Excel | |||
referencing named formula using INDIRECT function | Excel Worksheet Functions | |||
Simplify formula | Excel Worksheet Functions | |||
Match / Vlookup within an Array formula | Excel Discussion (Misc queries) |