?
Solved

Divide by 0 error in excel

Posted on 2012-09-20
4
Medium Priority
?
314 Views
Last Modified: 2012-09-20
I have an excel report that is pulling data from a link to another workbook.  The formula is working nicely if there is data.  I would like to show "0" if there is a #div/0 error.

I am getting a #div/0 error.  Below is my formula.  Can someone help please?

=AVERAGEIF('C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$B:$B,$A17,'C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$A:$A)
0
Comment
Question by:orther
  • 2
4 Comments
 
LVL 18

Expert Comment

by:Cluskitt
ID: 38417095
=ISERROR(AVERAGEIF('C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$B:$B,$A17,'C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$A:$A),0)
0
 

Author Comment

by:orther
ID: 38417117
When I run this I receive and error:

You've entered too many arguments for this function
0
 
LVL 50

Accepted Solution

by:
Ingeborg Hawighorst (Microsoft MVP / EE MVE) earned 2000 total points
ID: 38417142
The function is IFERROR and not ISERROR, so you need

=iferror(AVERAGEIF('C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$B:$B,$A17,'C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$A:$A),0)

IFERROR does not exist in Excel 2003 and earlier. To make this work in Excel before 2007, try

=if(iserror(AVERAGEIF('C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$B:$B,$A17,'C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$A:$A)),0,AVERAGEIF('C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$B:$B,$A17,'C:\DailyShippingBacklog\[WeeklyTurnaround.xlsx]Repair Module'!$A:$A))

cheers, teylyn
0
 

Author Closing Comment

by:orther
ID: 38417157
oh my an "Uber" formula:)
thanks
0

Featured Post

Prep for the ITIL® Foundation Certification Exam

December’s Course of the Month is now available! Enroll to learn ITIL® Foundation best practices for delivering IT services effectively and efficiently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how you can use Custom Document Properties to store settings and other information in your workbook so that they will be available the next time you open the workbook.
Windows Explorer let you handle zip folders nearly as any other folder: Copy, move, change, and delete, etc. In VBA you can also handle normal files and folders, but zip folders takes a little more - and that you'll find here.
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question