![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: May 2002
Posts: 6
|
Is there any Easy way to keep #DIV/0! from appearing in cells when there is no matching data to calculate in a formula?
Here's an example of the formula that I'm using... =SUMIF('Main Sheet'!$Q$7:$Q$176,"In-HouseWonderBall",'Main Sheet'!$I$7:$I$176)/SUMIF('Main Sheet'!$Q$7:$Q$176,"In-HouseWonderBall",'Main Sheet'!$H$7:HH$176) Again... if there's an easy solution that I can apply to all cells. THANK YOU!!!!! |
|
|
|
|
|
#2 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Austin, Texas USA
Posts: 11,654
|
Normally, one would use a formula such as...
=IF(B1,A1/B1,0) ...but, you didn't indicate what your wanted to return instead of #DIV/0! |
|
|
|
|
|
#3 | |
|
MrExcel MVP
Join Date: Feb 2002
Location: The Hague
Posts: 50,317
|
Quote:
=SUMIF('Main Sheet'!$Q$7:$Q$176,"In-HouseWonderBall",'Main Sheet'!$I$7:$I$176)/MAX(1,SUMIF('Main Sheet'!$Q$7:$Q$176,"In-HouseWonderBall",'Main Sheet'!$H$7:HH$176)) That's, if the second SUMIF result is never > 0 and < 1. Aladin [ This Message was edited by: Aladin Akyurek on 2002-05-09 12:14 ] |
|
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|