+ Reply to Thread
Results 1 to 7 of 7

#REF! to Zero?

  1. #1
    Forum Contributor
    Join Date
    04-30-2013
    Location
    D.C.
    MS-Off Ver
    Excel 2010
    Posts
    192

    #REF! to Zero?

    Hello Excellers,

    I am wondering how to combine these two formulas together in one:

    =SUMIF(D12488:D13009,""&X1,T12488:T13009)
    and
    =if(ISERROR(T13010,0,T13010)

    and I want to apply this forumla to the entire column (T:T). Maybe there is a better way to write this instead of combining the codes above?

    Thanks!!

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: #REF! to Zero?

    What is the logic supposed to be? Does T13010 contain the SUMIF formula?
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Forum Contributor
    Join Date
    04-30-2013
    Location
    D.C.
    MS-Off Ver
    Excel 2010
    Posts
    192

    Re: #REF! to Zero?

    Yes, the cell T13010 contains the formula =SUMIF(D12488:D13009,""&X1,T12488:T13009). When the ranges in D12488:D13009 and T12488:T13009 contain blanks, T13010 turns to #REF! error. I want it to display as a zero instead of #REF!. I also want to apply this same solution to the rest of the column T:T.

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: #REF! to Zero?

    The SUMIFformula should already result in 0 if the columns are blank, unless you are referencing a sheet that is not actually there.

  5. #5
    Forum Contributor
    Join Date
    04-30-2013
    Location
    D.C.
    MS-Off Ver
    Excel 2010
    Posts
    192

    Re: #REF! to Zero?

    I noticed that I ran ActiveSheet.Columns("B:B").SpecialCells(xlCellTypeBlanks).EntireRow.Delete in a macro and this causes the #REF! to appear. The report cannot have blank rows so it is referring to a cell that was empty and deleted. I only want to have the #REF! to be replaced with a zero.

  6. #6
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: #REF! to Zero?

    i can probably suggest:

    =IFERROR(SUMIF(D12488:D13009,""&X1,T12488:T13009),0)

  7. #7
    Forum Contributor
    Join Date
    04-30-2013
    Location
    D.C.
    MS-Off Ver
    Excel 2010
    Posts
    192

    Re: #REF! to Zero?

    Thanks!! It works!

    Marking this as SOLVED.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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