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. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
#Div/0! Error
I have the formula:
=(Sum([Estimated Budget (Mat'l)]+[Estimated Budget (Trans)]+[Estimated Budget (Labour)]))/(Sum([Completion Status]))/100 and when I run the report I get "#Div/0!" appearing where I placed the formula. When i run the report for a different number then the formula works. If it makes any difference, the numbers being entered are in the format of B01, B02, etc. Any help would be appreciated. |
#2
|
|||
|
|||
#Div/0! Error
Change the formula to look like this, because if Sum([Completion Status]) = 0 for any project, the divide by zero error will occur: =IIF((Sum([Completion Status]) = 0 or IsNull(Sum([Completion Status])), _ 0, Sum([Estimated Budget (Mat'l)]+[Estimated Budget (Trans)]+ _ [Estimated Budget (Labour)]))/(Sum([Completion Status]))/100) ( an _ means the line continues) This will check the value of the completion status before doing the divide. -- SA ACG Soft http://ourworld.compuserve.com/homepages/attac-cg "J" wrote in message oups.com... I have the formula: =(Sum([Estimated Budget (Mat'l)]+[Estimated Budget (Trans)]+[Estimated Budget (Labour)]))/(Sum([Completion Status]))/100 and when I run the report I get "#Div/0!" appearing where I placed the formula. When i run the report for a different number then the formula works. If it makes any difference, the numbers being entered are in the format of B01, B02, etc. Any help would be appreciated. |
#3
|
|||
|
|||
#Div/0! Error
How would you enter numbers "in the format of B01, B02, etc"?
I expect you have some Completion Status values of 0. Try something like: =IIf(Sum([Completion Status])=0,0, (Sum([Estimated Budget (Mat'l)]+[Estimated Budget (Trans)]+[Estimated Budget (Labour)]))/(Sum([Completion Status]))/100) -- Duane Hookom MS Access MVP -- "J" wrote in message oups.com... I have the formula: =(Sum([Estimated Budget (Mat'l)]+[Estimated Budget (Trans)]+[Estimated Budget (Labour)]))/(Sum([Completion Status]))/100 and when I run the report I get "#Div/0!" appearing where I placed the formula. When i run the report for a different number then the formula works. If it makes any difference, the numbers being entered are in the format of B01, B02, etc. Any help would be appreciated. |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How do you create customised error messages in Access? | Randall | General Discussion | 2 | February 24th, 2006 06:32 PM |
Can I prevent a #DIV/0! error from plotting on a chart | curious | Charts and Charting | 1 | August 26th, 2005 08:35 AM |
Help! I'm getting error messages too much-can't open Resume Wizard | LizLB | General Discussion | 0 | May 3rd, 2005 01:46 AM |
Help, i'm gettiing error: Access has encountered a problem and needs to close... | betsy | General Discussion | 0 | September 14th, 2004 08:20 PM |
Productkey problem when installing office 2003 on network | Stefan Schreurs | Setup, Installing & Configuration | 1 | June 1st, 2004 11:16 PM |