Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default using the countif function

Hi All
im using the countif function to add up all the cells in a range that
contain the Letter D the formula works but the problem im having is that if
there is on D in the range then the formula returns the 0 (zero) value how do
i get it to just leave the cell blank ??? ps ive tries addin ,"") this does
not work

cheers guys or gals
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 461
Default using the countif function

Just wrap the formula around in an If statement like

=If(Countif(yourrange,"D")=0,"",Countif(yourrange, "D"))

"harrimanxix" wrote:

Hi All
im using the countif function to add up all the cells in a range that
contain the Letter D the formula works but the problem im having is that if
there is on D in the range then the formula returns the 0 (zero) value how do
i get it to just leave the cell blank ??? ps ive tries addin ,"") this does
not work

cheers guys or gals

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,572
Default using the countif function

One way:

=IF(COUNTIF(B1:B100,"D"),COUNTIF(B1:B100,"D"),"")

--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"harrimanxix" wrote in message
...
Hi All
im using the countif function to add up all the cells in a range that
contain the Letter D the formula works but the problem im having is that
if
there is on D in the range then the formula returns the 0 (zero) value how
do
i get it to just leave the cell blank ??? ps ive tries addin ,"") this
does
not work

cheers guys or gals



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
please help how to combine IF function with Countif function Dinesh Excel Worksheet Functions 6 March 30th 06 08:28 PM
How do I use a countif function according to two other countif fu. Kirsty Excel Worksheet Functions 2 February 20th 06 11:44 AM
Embed a countif function in subtotal function? Stuck at work Excel Worksheet Functions 1 February 14th 06 03:19 AM
countif OR function nospam Excel Worksheet Functions 5 September 9th 05 01:30 AM
CountIf function Julie Excel Worksheet Functions 2 June 21st 05 10:27 PM


All times are GMT +1. The time now is 04:24 PM.

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"