ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Using IF function for inbetween cell values (https://www.excelbanter.com/excel-worksheet-functions/80837-using-if-function-inbetween-cell-values.html)

Ivano

Using IF function for inbetween cell values
 
Hi,
I would like to test a cell and run a formula if the cell is inbetween two
values. For example.
IF(A1 <is inbetween values 1 and 100,"YES", "NO")
I can't figure out how to tell Excel the inbetween part? do I use A1=1:100
or 1<A1100?

Thanks a lot for your help,


JE McGimpsey

Using IF function for inbetween cell values
 
One way:

=IF(AND(A11,A1<100),"YES","NO")

In article ,
Ivano wrote:

Hi,
I would like to test a cell and run a formula if the cell is inbetween two
values. For example.
IF(A1 <is inbetween values 1 and 100,"YES", "NO")
I can't figure out how to tell Excel the inbetween part? do I use A1=1:100
or 1<A1100?

Thanks a lot for your help,


bj

Using IF function for inbetween cell values
 
try
=if(and(A=1,A<=100),"yes","no")

"Ivano" wrote:

Hi,
I would like to test a cell and run a formula if the cell is inbetween two
values. For example.
IF(A1 <is inbetween values 1 and 100,"YES", "NO")
I can't figure out how to tell Excel the inbetween part? do I use A1=1:100
or 1<A1100?

Thanks a lot for your help,


Fred Smith

Using IF function for inbetween cell values
 
You want the And function, as in:

=if(and(a11,a1<100),true,false)

--
Regards,
Fred


"Ivano" wrote in message
...
Hi,
I would like to test a cell and run a formula if the cell is inbetween two
values. For example.
IF(A1 <is inbetween values 1 and 100,"YES", "NO")
I can't figure out how to tell Excel the inbetween part? do I use A1=1:100
or 1<A1100?

Thanks a lot for your help,




CLR

Using IF function for inbetween cell values
 
You could also set the formula up to allow you to put the Minimum (C1) and
Maximum (C2) limits in another cell and not have to go in and change the
formula itself if this condition arizes regularly.

=IF(AND(A1C1,A1<C2),"YES","NO")


Vaya con Dios,
Chuck, CABGx3




"Ivano" wrote:

Hi,
I would like to test a cell and run a formula if the cell is inbetween two
values. For example.
IF(A1 <is inbetween values 1 and 100,"YES", "NO")
I can't figure out how to tell Excel the inbetween part? do I use A1=1:100
or 1<A1100?

Thanks a lot for your help,


Ivano

Using IF function for inbetween cell values
 
thanks AND thanks AND thanks AND thanks .... get it "AND" : ))

"Ivano" wrote:

Hi,
I would like to test a cell and run a formula if the cell is inbetween two
values. For example.
IF(A1 <is inbetween values 1 and 100,"YES", "NO")
I can't figure out how to tell Excel the inbetween part? do I use A1=1:100
or 1<A1100?

Thanks a lot for your help,



All times are GMT +1. The time now is 09:03 PM.

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