Countif

bamaisgreat

Well-known Member
Joined
Jan 23, 2012
Messages
831
Office Version
  1. 365
Platform
  1. Windows
I need to edit the code below so it stops counting when it hits 0. SUggestions?

=COUNTIF(K5:K29,"<=30")
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
Can you please explain what you mean?
Te formula will never "Hit zero" unless there are no cells that match the criteria.
 
Upvote 0
The range of numbers its looking are shown below. If the number is 0 or like a -123 I need it to not show those.

[TABLE="width: 500"]
<tbody>[TR]
[TD][TABLE="width: 66"]
<colgroup><col></colgroup><tbody>[TR]
[TD]DAYS LEFT[/TD]
[/TR]
[TR]
[TD]167[/TD]
[/TR]
[TR]
[TD]868[/TD]
[/TR]
[TR]
[TD]-728[/TD]
[/TR]
[TR]
[TD] [/TD]
[/TR]
[TR]
[TD]132[/TD]
[/TR]
[TR]
[TD] [/TD]
[/TR]
[TR]
[TD]705[/TD]
[/TR]
[TR]
[TD] [/TD]
[/TR]
[TR]
[TD]727[/TD]
[/TR]
[TR]
[TD]728[/TD]
[/TR]
[TR]
[TD]1051[/TD]
[/TR]
[TR]
[TD] [/TD]
[/TR]
[TR]
[TD] [/TD]
[/TR]
[TR]
[TD]167[/TD]
[/TR]
[TR]
[TD]867[/TD]
[/TR]
[TR]
[TD]868[/TD]
[/TR]
[TR]
[TD]1463[/TD]
[/TR]
[TR]
[TD] [/TD]
[/TR]
[TR]
[TD] [/TD]
[/TR]
[TR]
[TD] [/TD]
[/TR]
[TR]
[TD]73[/TD]
[/TR]
[TR]
[TD]705[/TD]
[/TR]
[TR]
[TD]1051[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
 
Upvote 0

Forum statistics

Threads
1,223,886
Messages
6,175,194
Members
452,616
Latest member
intern444

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top