Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I'm trying to include a conditional however, I'm getting a sort of a syntax
error: =if((F5H5) AND (UPPER(C7) = "YES") AND (C9/C10 H9), "Yes", "No") F5 0.80 H5 0.75 C7 Yes C9 50000 C10 45000 C9/C10 = 1.11. H9 0.90 Any ideas? |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
"Jon" wrote:
I'm trying to include a conditional however, I'm getting a sort of a syntax error: =if((F5H5) AND (UPPER(C7) = "YES") AND (C9/C10 H9), "Yes", "No") =if(and(F5H4, UPPER(C7)="YES", C9/C10 H9), "Yes", "No") If C10 can be zero, you will want to do this differently, perhaps: =if(C10=0, "No", if(and(F5H4, UPPER(C7)="YES", C9/C10 H9), "Yes", "No")) or =if(C10=0, if(and(F5H4, UPPER(C7)="YES"), "Yes", "No"), if(and(F5H4, UPPER(C7)="YES", C9/C10 H9), "Yes", "No")) ----- original message ----- "Jon" wrote in message ... I'm trying to include a conditional however, I'm getting a sort of a syntax error: =if((F5H5) AND (UPPER(C7) = "YES") AND (C9/C10 H9), "Yes", "No") F5 0.80 H5 0.75 C7 Yes C9 50000 C10 45000 C9/C10 = 1.11. H9 0.90 Any ideas? |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
=if(and(F5H4, UPPER(C7)="YES", C9/C10 H9), "Yes", "No")
Remove the "UPPER" part. It's not a case senstive C7="Yes", or C7="YES", or C7="yEs" "Joe User" wrote: "Jon" wrote: I'm trying to include a conditional however, I'm getting a sort of a syntax error: =if((F5H5) AND (UPPER(C7) = "YES") AND (C9/C10 H9), "Yes", "No") =if(and(F5H4, UPPER(C7)="YES", C9/C10 H9), "Yes", "No") If C10 can be zero, you will want to do this differently, perhaps: =if(C10=0, "No", if(and(F5H4, UPPER(C7)="YES", C9/C10 H9), "Yes", "No")) or =if(C10=0, if(and(F5H4, UPPER(C7)="YES"), "Yes", "No"), if(and(F5H4, UPPER(C7)="YES", C9/C10 H9), "Yes", "No")) ----- original message ----- "Jon" wrote in message ... I'm trying to include a conditional however, I'm getting a sort of a syntax error: =if((F5H5) AND (UPPER(C7) = "YES") AND (C9/C10 H9), "Yes", "No") F5 0.80 H5 0.75 C7 Yes C9 50000 C10 45000 C9/C10 = 1.11. H9 0.90 Any ideas? |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Hi,
The syntax for AND is: AND(Condition1, Condition 2, Condition n) Try this syntax: =IF(AND(F5H5, UPPER(C7)="YES", C9/C10H9),"Yes","No") Note that if C10 is blank, you'll get a #DIV/0! (divide by zero) error. Regards - Dave. "Jon" wrote: I'm trying to include a conditional however, I'm getting a sort of a syntax error: =if((F5H5) AND (UPPER(C7) = "YES") AND (C9/C10 H9), "Yes", "No") F5 0.80 H5 0.75 C7 Yes C9 50000 C10 45000 C9/C10 = 1.11. H9 0.90 Any ideas? |
#5
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I'm trying to include a conditional however, I'm getting a sort of a
syntax error: =if((F5H5) AND (UPPER(C7) = "YES") AND (C9/C10 H9), "Yes", "No") The way to do logical AND in Excel is AND(condition1, condition2, condition3) So maybe this will meet the need: =IF(AND(F5H5, UPPER(C7)="YES", C9/C10H9), "Yes", "No") Or with an error check: =IF(C10=0, "undefined", IF(...as above...)) |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
[newbie] | Excel Discussion (Misc queries) | |||
Real Newbie newbie question | New Users to Excel | |||
Help for a newbie... please | Excel Worksheet Functions | |||
Help! Newbie | Excel Discussion (Misc queries) | |||
Newbie Help. Is this possible? | Excel Discussion (Misc queries) |