#1   Report Post  
Posted to microsoft.public.excel.misc
fivermsg
 
Posts: n/a
Default how can i do this?


here we go,

what i would like to do is take the value in g20 and m20 add them
together and take the average..BUT... if m20 equals #DIV/0! i still
want g20 to calculate..

ie- g20= 30 and M20= 30 then C20=30, this is good
ie- g20= 30 and M20= #DIV/0! then C20=30, this is good

But what i am getting is,

G20= 30 and M20= #DIV/0! then C20=15, this is not
good

any suggestions?


--
fivermsg
------------------------------------------------------------------------
fivermsg's Profile: http://www.excelforum.com/member.php...o&userid=32348
View this thread: http://www.excelforum.com/showthread...hreadid=521216

  #2   Report Post  
Posted to microsoft.public.excel.misc
SteveG
 
Posts: n/a
Default how can i do this?


Try this.

=IF(ISERROR(M20),G20,AVERAGE(G20,M20))


Does that help?

Steve


--
SteveG
------------------------------------------------------------------------
SteveG's Profile: http://www.excelforum.com/member.php...fo&userid=7571
View this thread: http://www.excelforum.com/showthread...hreadid=521216

  #3   Report Post  
Posted to microsoft.public.excel.misc
Irina
 
Posts: n/a
Default how can i do this?


fivermsg Wrote:
here we go,

what i would like to do is take the value in g20 and m20 add them
together and take the average..BUT... if m20 equals #DIV/0! i still
want g20 to calculate..

ie- g20= 30 and M20= 30 then C20=30, this is good
ie- g20= 30 and M20= #DIV/0! then C20=30, this is good

But what i am getting is,

G20= 30 and M20= #DIV/0! then C20=15, this is not
good

any suggestions?


May be you should check is it number or not. Something like this:
=IF(AND(ISNUMBER(A13),ISNUMBER(B13)),AVERAGE(A13:B 13),"")


--
Irina
------------------------------------------------------------------------
Irina's Profile: http://www.excelforum.com/member.php...fo&userid=8685
View this thread: http://www.excelforum.com/showthread...hreadid=521216

  #4   Report Post  
Posted to microsoft.public.excel.misc
Dave O
 
Posts: n/a
Default how can i do this?

Use the start of the formula from the previous post, and divide by the
count of numeric cells to get the simple average, comme ca:
=(IF(ISNUMBER(G20),G20)+IF(ISNUMBER(M20),M20))/COUNT(G20,M20)

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



All times are GMT +1. The time now is 01:12 PM.

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

About Us

"It's about Microsoft Excel"