ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   If Statements (https://www.excelbanter.com/excel-worksheet-functions/17609-re-if-statements.html)

JulieD

If Statements
 
Hi

you can't nest more than 7 IF's ... but you can use VLOOKUP instead - create
a table somewhere in your workbook consisting of two columns
.........A.............B
1.....Grade.......Value
2.......A..............4
3.......B..............3
etc

then instead of your IF use
=VLOOKUP(A1,Sheet2!$A$2:$B$11,2,0)
this says, lookup the value in A1 in the table on sheet 2 (ie the table as
outlined above) and return the associated value from the second column (ie
column B) where there is an exact match.

Hope this helps
Cheers
julieD


"NEWNEW" wrote:

I need to include more than 7 functions in an "IF" statement. It's so
simple, but I can't figure it out. What I need pertains to grades. In a
hidden column, I have basically "IF" A is entered, return 4; If B is entered,
return 3, etc., down to "F." However, I now need to include Honor Class
grades (A=4.5, B=3.5, C=2.5, and D=1.5). A, B, C, D, F, AH, BH, CH, DH --
that's 9. CAN ANYONE HELP ME!!??

THANK YOU


Naomi

You could either do a vlookup on a table that lists the results or, if you
want to keep it in the formula:

=SUMPRODUCT(({"a","b","c"}=A4)*({4.5,3.5,2.5}))

"NEWNEW" wrote:

I need to include more than 7 functions in an "IF" statement. It's so
simple, but I can't figure it out. What I need pertains to grades. In a
hidden column, I have basically "IF" A is entered, return 4; If B is entered,
return 3, etc., down to "F." However, I now need to include Honor Class
grades (A=4.5, B=3.5, C=2.5, and D=1.5). A, B, C, D, F, AH, BH, CH, DH --
that's 9. CAN ANYONE HELP ME!!??

THANK YOU



All times are GMT +1. The time now is 04:30 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com