+ Reply to Thread
Results 1 to 7 of 7

Depleting one cell until zero with excess to be subtracted from next designated cell

Hybrid View

  1. #1
    Registered User
    Join Date
    01-11-2013
    Location
    Dallas, Texas
    MS-Off Ver
    Excel 2010
    Posts
    2

    Depleting one cell until zero with excess to be subtracted from next designated cell

    I have two cells at the top of the sheet that have different values ie(A1 & B2). Next I have a column of all different values ie(D1:D5) that need to be subtracted from A1 until A1 reaches zero. The remaining if any need to subtracted from B2.
    Attached Files Attached Files
    Last edited by hassingerl; 01-17-2013 at 09:16 PM.

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,049

    Re: Depleting one cell until zero with excess to be subtracted from next designated cell

    Hi hassinggerl and welcome to the forum

    If you already have a sample workbook, please upload that, and no a picture or pdf file.
    To attach a file to your post,
    click advanced (next to quick post),
    scroll down until you see "manage file",
    click that and select "add files" (top right corner).
    click "select files" find your file, click "open" click "upload" click 'done" bottom right. click "submit reply"

    Once the upload is completed the file name will appear below the input boxes in this window.
    You can then close the window to return to the new post screen.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    01-11-2013
    Location
    Dallas, Texas
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: Depleting one cell until zero with excess to be subtracted from next designated cell

    I'm looking for a formula that can be copied down through the columns titled bucket 1 & 2.
    Attached Files Attached Files

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,049

    Re: Depleting one cell until zero with excess to be subtracted from next designated cell

    thanks :0

    in E6, copied down use this...
    =IF(E5-C5<0,0,E5-C5)

    in H7, copied down, use this...
    =IF(H6-E7-C7<0,0,IF(E7>C7,H6,H6-E7-C7))

  5. #5
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Depleting one cell until zero with excess to be subtracted from next designated cell

    In E6:
    =IF(AND(ISNUMBER(E5),E5>0),IF(E5-C5<0,"",E5-C5),"")
    Copied down
    In H6:
    =IF(AND(E6>0,E6-C6<0),I5-ABS(E6-C6),IF(AND(H5<H5,H5>0),IF(H5-C6<0,"",H5-C6),IF(AND(ISNUMBER(H5),HI5>0),H5,"")))
    copied down

    Hope this helps
    Last edited by dredwolf; 01-17-2013 at 10:36 PM.
    A picture may be worth a thousand words, BUT, a sample Workbook is worth a thousand screenshots!
    -Add a File - click advanced (next to quick post), scroll to manage attachments, click, select add files, click select files, select file, click upload, when file shows up at bottom left, click done (bottom right), click submit
    -To mark thread Solved- go top of thread,click Thread Tools,click Mark as Solved
    If you received helpful response, please remember to hit the * of that post

  6. #6
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Depleting one cell until zero with excess to be subtracted from next designated cell

    ignore last post by me...made some copy paste errors...sorry

  7. #7
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Depleting one cell until zero with excess to be subtracted from next designated cell

    In E6:
    =IF(ISNUMBER(E5),IF(E5-C5<0,"",E5-C5),"")
    Drag Down
    In H6:
    =IF(ISNUMBER(E6),IF(E6-C6<0,H5-ABS(E6-C6),H5),IF(ISNUMBER(H5),IF(H5-C6<0,"",H5-C6),""))
    Drag down

    While fixing the transposition errors I noticed some easier ways to do same thing, that's why it took so long to get back

    Hope THIS helps

+ 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