ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   IF..AND Statement (https://www.excelbanter.com/excel-worksheet-functions/109380-if-statement.html)

HBuck

IF..AND Statement
 
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli


Don Guillett

IF..AND Statement
 
try
=IF(AND(C4=0, C4<=25), "XXX","")
--
Don Guillett
SalesAid Software

"HBuck" wrote in message
ups.com...
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli




Dave Peterson

IF..AND Statement
 
I bet you really want AND.

=if(and(c4=0,c4<=25),"xxx","")

But this formula can't go in C4. It has to go into another cell.



HBuck wrote:

Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli


--

Dave Peterson

HBuck

IF..AND Statement
 
Just after submitting this problem to the group, I actually solved it.

HBuck


HBuck wrote:
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli



HBuck

IF..AND Statement
 
Thank you Don!

Your solution is actually more accurate than my own.

HBuck



Don Guillett wrote:
try
=IF(AND(C4=0, C4<=25), "XXX","")
--
Don Guillett
SalesAid Software

"HBuck" wrote in message
ups.com...
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli



Dave F

IF..AND Statement
 
=IF(AND(C4=0,C4<=25),"XXX","")

"IF C4 is greater than 0 AND C4 is less than or equal to 25, THEN "XXX",
ELSE "" "

If that's the logic you're looking for, then use the formula above.

Dave
--
Brevity is the soul of wit.


"HBuck" wrote:

Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli



Allllen

IF..AND Statement
 
You are trying for an OR, not an AND. So I think Don just missed that.
It should be

=IF(OR(C4=0,C4<=25),"XXX","")

--
Allllen


"Don Guillett" wrote:

try
=IF(AND(C4=0, C4<=25), "XXX","")
--
Don Guillett
SalesAid Software

"HBuck" wrote in message
ups.com...
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli





Don Guillett

IF..AND Statement
 
glad to help

--
Don Guillett
SalesAid Software

"HBuck" wrote in message
oups.com...
Thank you Don!

Your solution is actually more accurate than my own.

HBuck



Don Guillett wrote:
try
=IF(AND(C4=0, C4<=25), "XXX","")
--
Don Guillett
SalesAid Software

"HBuck" wrote in message
ups.com...
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli





Bernard Liengme

IF..AND Statement
 
=IF(OR(C4=0, C4<=25), "XXX","")
best wishes
--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"HBuck" wrote in message
ups.com...
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli




John Fuller

IF..AND Statement
 
Not to harp, but everyone who is saying to use:
=IF(OR(C4=0, C4<=25), "XXX","")

That will result in "XXX" being displayed if C4 contains a number, any
number. Because any number is either greater than 0 or less than 25,
or even both.


Bernard Liengme wrote:
=IF(OR(C4=0, C4<=25), "XXX","")
best wishes
--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"HBuck" wrote in message
ups.com...
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli



Allllen

IF..AND Statement
 
yup. but that is what was asked for very specifically and very clearly. so
it is no surprise that people have answered in different ways.

anyway I think Holli will have got what she wants out of this

--
Allllen


"John Fuller" wrote:

Not to harp, but everyone who is saying to use:
=IF(OR(C4=0, C4<=25), "XXX","")

That will result in "XXX" being displayed if C4 contains a number, any
number. Because any number is either greater than 0 or less than 25,
or even both.


Bernard Liengme wrote:
=IF(OR(C4=0, C4<=25), "XXX","")
best wishes
--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"HBuck" wrote in message
ups.com...
Hello,

I'm sure that this is a no-brainer for most of you, so that is why I am
posting in this forum.

I am trying to fill in cells in a worksheet using an IF..AND statement,
but it's not working properly, so I'm obviously doing something wrong.
The statement that I am using is:
=IF(AND(C4=0, OR(C4<=25)), "XXX","") and I'm trying to find a value
within a range.

What I want to say is:

If C4 =0
OR
C4<=25
THEN C4 = XXX
ELSE "blank"

Did I set that formula up incorrectly? Should I not use the AND
statement and have nested IFs instead? The problem that I have is it's
not doing the value check on the cell, so it doesn't place the 'XXX's
in the proper cell.

Any help would be greatly appreciated.

Holli





All times are GMT +1. The time now is 06:54 AM.

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