+ Reply to Thread
Results 1 to 6 of 6

#div/0! with a twist

  1. #1
    Registered User
    Join Date
    10-05-2011
    Location
    NYC
    MS-Off Ver
    Excel 2010 Professional Plus
    Posts
    44

    #div/0! with a twist

    I am receiving the typical #div/0! error. I know what is causing the error, but I would very much like to resolve the error message with a method other than utilizing an IF statement within the current function.

    My reason for this preference is that the current formula that is causing the error message is already rather long (see below) and is applied to a very large number of cells, which requires up to 40 seconds to process in its entirety when an update is made. An IF statement that repeats a large portion of the formula would lengthen the process time even moreso.


    =(SUMPRODUCT(SUMIFS('Cash Receipts'!$F:$F,'Cash Receipts'!$A:$A,Income,'Cash Receipts'!$B:$B,$A35,'Cash Receipts'!$I:$I,">="&C$1,'Cash Receipts'!$I:$I,"<="&C$2))-SUMPRODUCT(COUNTIFS('Cash Receipts'!$A:$A,Income,'Cash Receipts'!$B:$B,$A35,'Cash Receipts'!$I:$I,">="&C$1,'Cash Receipts'!$I:$I,"<="&C$2))*(EOMONTH(C$1,0)+1))/SUMPRODUCT(COUNTIFS('Cash Receipts'!$A:$A,Income,'Cash Receipts'!$B:$B,$A35,'Cash Receipts'!$I:$I,">="&C$1,'Cash Receipts'!$I:$I,"<="&C$2))

    I realize a workaround would be to insert the IF(ISERROR... function into another column on the same spreadsheet and hide the column with the errors, but I'm holding out hope for some method that simplifies the function or at the very least does not require additional time to process the function.

    Any help would be appreciated.

    Cheers

    Bjordion
    Last edited by Bjordion; 11-11-2011 at 03:53 PM.

  2. #2
    Forum Expert ConneXionLost's Avatar
    Join Date
    03-11-2009
    Location
    Victoria, Canada
    MS-Off Ver
    2010
    Posts
    2,952

    Re: #div/0! with a twist

    The Excel version listed in your profile (Excel 1020?) might indicate you could use IFERROR instead of IF/ISERROR which, would save some real estate for you.

    Also, your use of the three SUMPRODUCT functions appears redundant. What happens if you remove them from your formula?

    Cheers,
    Would you like to say thanks? Please click the: " Add Reputation" button, on the grey bar below the post.

  3. #3
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: #div/0! with a twist

    @ connexionlost excel 1020 was an abacus!
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  4. #4
    Registered User
    Join Date
    10-05-2011
    Location
    NYC
    MS-Off Ver
    Excel 2010 Professional Plus
    Posts
    44

    Re: #div/0! with a twist

    Hahaha, yes the little known version 1020. Thank you for alerting me to that.

    I agree with you on the SUMPRODUCT function, but I already have tried removing it. Doing so causes another #div/0! error.

  5. #5
    Forum Expert ConneXionLost's Avatar
    Join Date
    03-11-2009
    Location
    Victoria, Canada
    MS-Off Ver
    2010
    Posts
    2,952

    Re: #div/0! with a twist

    Abacus? - I don't think I have a copy of that version.

    In any case, the IFERROR function hides many crimes.

    Any chance you could post a sample worksheet?

  6. #6
    Registered User
    Join Date
    10-05-2011
    Location
    NYC
    MS-Off Ver
    Excel 2010 Professional Plus
    Posts
    44

    Re: #div/0! with a twist

    Thank you for the IFERROR suggestion, if nothing else I will use that.

    Unfortunately I would have to heavily, heavily modify the worksheet to remove all confidential information prior to posting, something I don't have time for at the moment.

    Thank you very much for your assistance, it is much appreciated.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1