Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Steved
 
Posts: n/a
Default Countif statement

Hello from Steved

How do I have the below work, I want Yes to be displayed if
Column does not have OK in the M Column please.

=IF(COUNTIF($M$1:$M$4999,"<OK"), "YES","NO")

The above formula resides in Cell L1

Thankyou.


  #2   Report Post  
bj
 
Posts: n/a
Default

try
=if(countif($M$1:$M$4999,"OK")0,"NO","YES")

"Steved" wrote:

Hello from Steved

How do I have the below work, I want Yes to be displayed if
Column does not have OK in the M Column please.

=IF(COUNTIF($M$1:$M$4999,"<OK"), "YES","NO")

The above formula resides in Cell L1

Thankyou.


  #3   Report Post  
Steved
 
Posts: n/a
Default

Hello bj from Steved

If a figure sat 12,975 appears instead off OK,I would like it to say No

Please excuse me for the misunderstanding.

As at the moment if their is a change with your formula nothing happens.

Thankyou.

"bj" wrote:

try
=if(countif($M$1:$M$4999,"OK")0,"NO","YES")

"Steved" wrote:

Hello from Steved

How do I have the below work, I want Yes to be displayed if
Column does not have OK in the M Column please.

=IF(COUNTIF($M$1:$M$4999,"<OK"), "YES","NO")

The above formula resides in Cell L1

Thankyou.


  #5   Report Post  
bj
 
Posts: n/a
Default

I may not understand what you want.

If I read the original message correctly, no Cell in M1 to M4999 can have
an "OK" for L1 to say "Yes". if Any Cell has an "OK" then L1 will say "No"

Do you want L1 to refer only to M1, L2 only to M2?

Do you also want it to say "NO" if any number shows in any of the cells

"Steved" wrote:

Hello bj from Steved

If a figure sat 12,975 appears instead off OK,I would like it to say No

Please excuse me for the misunderstanding.

As at the moment if their is a change with your formula nothing happens.

Thankyou.

"bj" wrote:

try
=if(countif($M$1:$M$4999,"OK")0,"NO","YES")

"Steved" wrote:

Hello from Steved

How do I have the below work, I want Yes to be displayed if
Column does not have OK in the M Column please.

=IF(COUNTIF($M$1:$M$4999,"<OK"), "YES","NO")

The above formula resides in Cell L1

Thankyou.




  #6   Report Post  
Steved
 
Posts: n/a
Default

Hello from Steved

$M$1:$M$4999

if M1:M4999 all has "OK" the answer is yes

if M1:M4999 all has not got "OK" the answer is No

I'm sorry about the confusion the cell L1 is where I will put your formula.

Cheers.



"bj" wrote:

I may not understand what you want.

If I read the original message correctly, no Cell in M1 to M4999 can have
an "OK" for L1 to say "Yes". if Any Cell has an "OK" then L1 will say "No"

Do you want L1 to refer only to M1, L2 only to M2?

Do you also want it to say "NO" if any number shows in any of the cells

"Steved" wrote:

Hello bj from Steved

If a figure sat 12,975 appears instead off OK,I would like it to say No

Please excuse me for the misunderstanding.

As at the moment if their is a change with your formula nothing happens.

Thankyou.

"bj" wrote:

try
=if(countif($M$1:$M$4999,"OK")0,"NO","YES")

"Steved" wrote:

Hello from Steved

How do I have the below work, I want Yes to be displayed if
Column does not have OK in the M Column please.

=IF(COUNTIF($M$1:$M$4999,"<OK"), "YES","NO")

The above formula resides in Cell L1

Thankyou.


  #7   Report Post  
Aladin Akyurek
 
Posts: n/a
Default

=(COUNTIF($M$1:$M$4999,"OK")=ROWS($M$1:$M$4999))+0

Custom format the formula cell as:

[=0]"No";[=1]"Yes"

Steved wrote:
Hello from Steved

$M$1:$M$4999

if M1:M4999 all has "OK" the answer is yes

if M1:M4999 all has not got "OK" the answer is No

[...]
  #8   Report Post  
bj
 
Posts: n/a
Default

try

=if(or(M1:M4999<"OK"),"NO","YES")

entered as an array formula (Control-Shift-Enter)

"Steved" wrote:

Hello from Steved

$M$1:$M$4999

if M1:M4999 all has "OK" the answer is yes

if M1:M4999 all has not got "OK" the answer is No

I'm sorry about the confusion the cell L1 is where I will put your formula.

Cheers.



"bj" wrote:

I may not understand what you want.

If I read the original message correctly, no Cell in M1 to M4999 can have
an "OK" for L1 to say "Yes". if Any Cell has an "OK" then L1 will say "No"

Do you want L1 to refer only to M1, L2 only to M2?

Do you also want it to say "NO" if any number shows in any of the cells

"Steved" wrote:

Hello bj from Steved

If a figure sat 12,975 appears instead off OK,I would like it to say No

Please excuse me for the misunderstanding.

As at the moment if their is a change with your formula nothing happens.

Thankyou.

"bj" wrote:

try
=if(countif($M$1:$M$4999,"OK")0,"NO","YES")

"Steved" wrote:

Hello from Steved

How do I have the below work, I want Yes to be displayed if
Column does not have OK in the M Column please.

=IF(COUNTIF($M$1:$M$4999,"<OK"), "YES","NO")

The above formula resides in Cell L1

Thankyou.


  #9   Report Post  
Sandy Mann
 
Posts: n/a
Default

"Aladin Akyurek" wrote in message
...
=(COUNTIF($M$1:$M$4999,"OK")=ROWS($M$1:$M$4999))+0


Aladin,

May I ask, when you have hard coded $M$4999 into the formula and
ROWS($M$1:$M$4999) returns 4999, why did you not just use =4999?

I thought that it was to account for inserted rows above the data but if you
insert 10 rows the fomula automatically changes to:

=(COUNTIF($M$11:$M$5009,"OK")=ROWS($M$11:$M$5009)) +0

and the ROWS($M$11:$M$5009) of course still evaluates to 4999

--
Puzzled but wanting to learn,

Sandy

Replace@mailinator with @tiscali.co.uk


  #10   Report Post  
Aladin Akyurek
 
Posts: n/a
Default



Sandy Mann wrote:
"Aladin Akyurek" wrote in message
...

=(COUNTIF($M$1:$M$4999,"OK")=ROWS($M$1:$M$4999)) +0



Aladin,

May I ask, when you have hard coded $M$4999 into the formula and
ROWS($M$1:$M$4999) returns 4999, why did you not just use =4999?

I thought that it was to account for inserted rows above the data but if you
insert 10 rows the fomula automatically changes to:

=(COUNTIF($M$11:$M$5009,"OK")=ROWS($M$11:$M$5009)) +0

and the ROWS($M$11:$M$5009) of course still evaluates to 4999


If rows in between would be deleted for some reason, the formula would
break down, hence ROWS(...).


  #11   Report Post  
Sandy Mann
 
Posts: n/a
Default

If rows in between would be deleted for some reason, the formula would
break down, hence ROWS(...).


Ah! I thought of rows before, rows after......... never thought of rows
between

--
Thank you Aladin,


Sandy

Replace@mailinator with @tiscali.co.uk



  #12   Report Post  
Steved
 
Posts: n/a
Default

Thanks bj

"bj" wrote:

try

=if(or(M1:M4999<"OK"),"NO","YES")

entered as an array formula (Control-Shift-Enter)

"Steved" wrote:

Hello from Steved

$M$1:$M$4999

if M1:M4999 all has "OK" the answer is yes

if M1:M4999 all has not got "OK" the answer is No

I'm sorry about the confusion the cell L1 is where I will put your formula.

Cheers.



"bj" wrote:

I may not understand what you want.

If I read the original message correctly, no Cell in M1 to M4999 can have
an "OK" for L1 to say "Yes". if Any Cell has an "OK" then L1 will say "No"

Do you want L1 to refer only to M1, L2 only to M2?

Do you also want it to say "NO" if any number shows in any of the cells

"Steved" wrote:

Hello bj from Steved

If a figure sat 12,975 appears instead off OK,I would like it to say No

Please excuse me for the misunderstanding.

As at the moment if their is a change with your formula nothing happens.

Thankyou.

"bj" wrote:

try
=if(countif($M$1:$M$4999,"OK")0,"NO","YES")

"Steved" wrote:

Hello from Steved

How do I have the below work, I want Yes to be displayed if
Column does not have OK in the M Column please.

=IF(COUNTIF($M$1:$M$4999,"<OK"), "YES","NO")

The above formula resides in Cell L1

Thankyou.


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding an AND Statement to COUNTIF Kenton_SJ Excel Worksheet Functions 2 June 17th 05 11:59 PM
Do I need a sumif or sum of a vlookup formula? PeterB Excel Worksheet Functions 0 June 1st 05 12:23 PM
COUNTIF Statement with Multiple Conditions in Different Ranges KJA Excel Worksheet Functions 2 April 26th 05 05:14 PM
Countif Function with and Statement Matt Excel Worksheet Functions 3 March 4th 05 08:32 PM
countif statement Russell Hampton Excel Worksheet Functions 6 December 18th 04 07:39 PM


All times are GMT +1. The time now is 01:18 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"