+ Reply to Thread
Results 1 to 10 of 10

Subtract value from a max sum

  1. #1
    Registered User
    Join Date
    08-16-2015
    Location
    Denmark
    MS-Off Ver
    Excel 2010
    Posts
    13

    Subtract value from a max sum

    Hi guys
    I have an excel problem I can't solve myself.

    A customer save up half an hour each week.
    A1 (week 1) = 0,5
    B1 (week 2) = 0,5
    C1 (week 3) = 0,5
    Etc.

    A customer can max save up 6 hours in total.

    Then I have a row with the spendings:
    A2 (week 1) = (blank)
    B2 (week 2) = (blank)
    C2 (week 3) = 1
    Etc.

    I can't figure out this:
    If a customer save up and dont spend any until week 24. I can get sum to show 6 by using the IF formula.
    And thats great.
    The problem is that when the customer spend 3 hours in week 24. The result should be 3 hours left.
    But it still shows 6 (because he saved up 12 hours before he spent any, But he can only save up 6 hours).

    Sorry for my bad english.
    I hope I made myself clear.

    Can Anybody help me?

    Cheers,
    Martin
    Attached Files Attached Files
    Last edited by Kaas; 08-16-2015 at 03:52 AM.

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,101

    Re: Subtract value from a max sum

    Hi there. welcome to the forum. Does this do what you want? If not, please attach an Excel sheet, showing your data layout.

    =MIN(6,SUM(A1:X1))-SUM(A2:X2)
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  3. #3
    Registered User
    Join Date
    08-16-2015
    Location
    Denmark
    MS-Off Ver
    Excel 2010
    Posts
    13

    Re: Subtract value from a max sum

    Thanks for your answer.
    I still cant get it to Work.
    It subtract like it should, if I insert 2 in week 46, it shows 4 in total.
    But when they continue to save up it should show 4,5 in week 47 and it doesn´t :-(
    I attached my file.

  4. #4
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,101

    Re: Subtract value from a max sum

    No file attached...

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    The paperclip icon

  5. #5
    Registered User
    Join Date
    08-16-2015
    Location
    Denmark
    MS-Off Ver
    Excel 2010
    Posts
    13

    Re: Subtract value from a max sum

    Still no attached fil?
    I see it on my laptop.

  6. #6
    Registered User
    Join Date
    08-16-2015
    Location
    Denmark
    MS-Off Ver
    Excel 2010
    Posts
    13

    Re: Subtract value from a max sum

    On my first post.

  7. #7
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,101

    Re: Subtract value from a max sum

    OK. I see it... I was looking at your most recent post...

  8. #8
    Registered User
    Join Date
    08-16-2015
    Location
    Denmark
    MS-Off Ver
    Excel 2010
    Posts
    13

    Re: Subtract value from a max sum

    Still can't figure this out.
    Does Anybody know how to do this?

  9. #9
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,101

    Re: Subtract value from a max sum

    Try this... My Danish is non-existent, but I think that this is compatible with your data layout.
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    08-16-2015
    Location
    Denmark
    MS-Off Ver
    Excel 2010
    Posts
    13

    Re: Subtract value from a max sum

    Thank you very much.
    This Works great :-)

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Add and subtract
    By caziscarol in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-20-2015, 08:56 AM
  2. How to set max value and have it subtract from that max value?
    By jkwinel in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-24-2013, 11:03 AM
  3. [SOLVED] Trying to subtract
    By mlg1976 in forum Excel - New Users/Basics
    Replies: 6
    Last Post: 08-24-2012, 05:27 PM
  4. If Sat subtract one day, if Sunday subtract tow days
    By Wskip49 in forum Excel General
    Replies: 3
    Last Post: 06-30-2012, 03:35 PM
  5. Replies: 1
    Last Post: 01-27-2012, 11:25 PM
  6. Subtract If
    By NFJim in forum Excel General
    Replies: 5
    Last Post: 04-21-2010, 12:17 PM
  7. how to subtract one row from the other?
    By prasad in forum Excel General
    Replies: 1
    Last Post: 04-08-2005, 04:06 PM

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