A Microsoft Excel forum. ExcelBanter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » ExcelBanter forum » Excel Newsgroups » Excel Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Averageif Error



 
 
Thread Tools Display Modes
  #1  
Old October 2nd 09, 07:13 PM posted to microsoft.public.excel.worksheet.functions
Curtis
external usenet poster
 
Posts: 181
Default Averageif Error

I am using the formula

averageif($G219:$N219,"<>0") in my workbook however if one of the cells
contains "0" it returns the error #DIV/0!

Why and how can I get rid of it

Thanks
Ads
  #2  
Old October 2nd 09, 07:22 PM posted to microsoft.public.excel.worksheet.functions
Jacob Skaria
external usenet poster
 
Posts: 8,521
Default Averageif Error

In excel 2007 the below works if atleast there is one entry which is not = 0
=AVERAGEIF($G219:$N219,"<>0")

If you mean to avoid div error if all the cell values are 0 then try the below
=IF(SUM($G219:$N219),AVERAGEIF($G219:$N219,"<>0"), "")


If this post helps click Yes
---------------
Jacob Skaria


"Curtis" wrote:

> I am using the formula
>
> averageif($G219:$N219,"<>0") in my workbook however if one of the cells
> contains "0" it returns the error #DIV/0!
>
> Why and how can I get rid of it
>
> Thanks

  #3  
Old October 2nd 09, 10:02 PM posted to microsoft.public.excel.worksheet.functions
Dave Peterson
external usenet poster
 
Posts: 35,220
Default Averageif Error

Actually, you're getting the error if there are no cells that are non-zero,
right?

If the range is always numeric, then you could use:
=if(countif($g219:$n219,"<>0")=0,"no numbers",your formula here)

Or you could check to see if the only numbers were 0's:
=IF(COUNT($G219:$N219)=COUNTIF($G219:$N219,0),"no numbers","your formula here")



Curtis wrote:
>
> I am using the formula
>
> averageif($G219:$N219,"<>0") in my workbook however if one of the cells
> contains "0" it returns the error #DIV/0!
>
> Why and how can I get rid of it
>
> Thanks


--

Dave Peterson
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
AVERAGEIF T. Valko Excel Worksheet Functions 9 July 15th 09 07:01 PM
Help with Averageif Formula (don't think I should use Averageif) MUmfleet Excel Discussion (Misc queries) 5 April 9th 09 04:53 PM
AverageIF coastal Excel Discussion (Misc queries) 1 November 13th 07 11:28 PM
averageif name Excel Worksheet Functions 1 May 4th 06 05:27 PM
averageif rudy Excel Discussion (Misc queries) 5 April 27th 06 11:20 PM


All times are GMT +1. The time now is 10:52 PM.


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