+ Reply to Thread
Results 1 to 14 of 14

Deleting rows leads to #ref

  1. #1
    Registered User
    Join Date
    12-02-2012
    Location
    Harrow
    MS-Off Ver
    Excel 2003
    Posts
    73

    Deleting rows leads to #ref

    Hi I have a table of which gets bigger or smaller depending on number of inputs. One of the columns is a sumation of individual cells, when i delete a row however this leads to #ref as the cell it is looking for is no longer there. Is there anyway of avoiding this.

    Thanks

  2. #2
    Forum Contributor
    Join Date
    11-05-2012
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    229

    Re: Deleting rows leads to #ref

    You could look at using OFFSET.

    To learn how to do that, go here.

    Don't forget to click on the little star at the bottom left of this post if you feel I helped!
    Taming the Excel dragon... www.TheExcelphile.com

  3. #3
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643
    What formula are you using for the sum?
    If posting code please use code tags, see here.

  4. #4
    Registered User
    Join Date
    12-02-2012
    Location
    Harrow
    MS-Off Ver
    Excel 2003
    Posts
    73

    Re: Deleting rows leads to #ref

    HI I have two columns a + b

    the formula in the sum is Sum((a1*b1) + (a2*b2) + (a3*b3)) etc

  5. #5
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Deleting rows leads to #ref

    Is that copied down all the rows of the table?

  6. #6
    Registered User
    Join Date
    12-02-2012
    Location
    Harrow
    MS-Off Ver
    Excel 2003
    Posts
    73

    Re: Deleting rows leads to #ref

    Hi Norie

    Yes its is , same formula all the way down.

  7. #7
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Deleting rows leads to #ref

    Can you attach a sample workbook?

  8. #8
    Registered User
    Join Date
    12-02-2012
    Location
    Harrow
    MS-Off Ver
    Excel 2003
    Posts
    73

    Re: Deleting rows leads to #ref

    HI Noorie

    I have attached spreadsheet.

    Problem occurs in (cashflow tab) Cell I96 an M196 whenever I delete a row.

    This also leads to issues further down.

    So for example, if i delete Row 17 I also need to delete Rows 127 -134 manually (I dont know how to link the two tables together. This then gives me a Ref in T142

    Thanks
    Attached Files Attached Files

  9. #9
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Deleting rows leads to #ref

    Do the formulas in B196 to H196 not get affected?
    Last edited by Norie; 12-07-2012 at 10:02 AM.

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

    Re: Deleting rows leads to #ref

    one thing i have noticed is that
    =((M17*J17)+(M18*J18)+(M19*J19)+(M20*J20)+(M21*J21)+(M22*J22)+(M23*J23)+(M24*J24)+(M25*J25)+(M26*J26)+(M27*J27)+(M28*J28)+(M29*J29)+(M30*J30)+(M31*J31)+(M32*J32)+(M33*J33)+(M34*J34)+(M35*J35)+(M36*J36))/(J38-J37)
    can be just
    =SUMPRODUCT(M17:M36,J17:J36)/(J38-J37)
    "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

  11. #11
    Registered User
    Join Date
    12-02-2012
    Location
    Harrow
    MS-Off Ver
    Excel 2003
    Posts
    73

    Re: Deleting rows leads to #ref

    HI Noorie

    Will make that change, thanks. And from that how would I use offset i that context?

    Just looking at your previous comment to see what else goes wrong when i delete rows.


    Many thanks fr your help!

  12. #12
    Registered User
    Join Date
    12-02-2012
    Location
    Harrow
    MS-Off Ver
    Excel 2003
    Posts
    73

    Re: Deleting rows leads to #ref

    HI Noorie

    Your sumproduct worked and solved the problem, Thanks the issue I have now is when I delete say rows 127:134 it leads to refs in the cells bellow, which I cant seem to understand as there arent any links,

  13. #13
    Registered User
    Join Date
    12-02-2012
    Location
    Harrow
    MS-Off Ver
    Excel 2003
    Posts
    73

    Re: Deleting rows leads to #ref

    HI Please

    ignore as I have realised where the link was!

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

    Re: Deleting rows leads to #ref

    i seem to be noorie now

+ 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