+ Reply to Thread
Results 1 to 15 of 15

Subtract inventory based on date

  1. #1
    Registered User
    Join Date
    07-30-2018
    Location
    Atlanta, Georgia
    MS-Off Ver
    2018
    Posts
    11

    Subtract inventory based on date

    Hello,
    I am trying to see if there is a way to keep an automatic total of how much inventory I have on the floor based on date.
    My first column has the total I started with at the beginning of the week, and then a column for each day with the quantity sold each day. I want a new column that shows how much is currently on the floor based on what day it is. I'm currently manually adding columns to the formula each day,but obviously this is not efficient.
    For example,
    I start with 100 cases of product at the beginning of the week. I plan to sell 20 cases on 8/1, 10 cases on 8/2, 10 cases on 8/3, 20 cases on 8/4, and 10 cases on 8/5. How can it auto-calculate so when I open the worksheet on 8/1, it shows I have 80 cases left, and then on 8/4 the same cell shows I have 40 cases left?

    Thanks in advance!

  2. #2
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Subtract inventory based on date

    It can be setup with formulas using Today() which would be today's date.
    Can you post a sample file with your setup and where you want the result posted?
    It will be easy to offer solution if we have a sample workbook.
    1. Click on the * Add Reputation if you think this helped you
    2. Mark your thread as SOLVED when question is resolved

    Modytrane

  3. #3
    Registered User
    Join Date
    07-30-2018
    Location
    Atlanta, Georgia
    MS-Off Ver
    2018
    Posts
    11

    Re: Subtract inventory based on date

    Hello and thanks for your reply. I have attached a sample version, and the highlighted area is where I'd like the current available inventory. That way, we can see how much we started with, how much we have today, and how much we'll have at the end of the week.
    Attached Files Attached Files

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,778

    Re: Subtract inventory based on date

    Could you please manually fill in the results you are expecting in the yellow cells?
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  5. #5
    Registered User
    Join Date
    07-30-2018
    Location
    Atlanta, Georgia
    MS-Off Ver
    2018
    Posts
    11

    Re: Subtract inventory based on date

    I have put in the expected if I opened the worksheet on 8/1. Thanks!
    Attached Files Attached Files

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,778

    Re: Subtract inventory based on date

    I think you want this:

    =B2-SUMIF($E$1:$I$1,"<="&TODAY(),$E2:$I2)

    When you've entered the formula, make sure you set the cell format to general before drag copying down, otherwise it will return a date!

  7. #7
    Registered User
    Join Date
    07-30-2018
    Location
    Atlanta, Georgia
    MS-Off Ver
    2018
    Posts
    11

    Re: Subtract inventory based on date

    Thanks! I have tried it on an older week to see if it subtracts everything, and it still returns as if nothing has gone out yet. I have changed the cell formats for the headers to date, and the cells to general. What am I doing wrong?

  8. #8
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,778

    Re: Subtract inventory based on date

    How would I know without seeing what you've done?

    It may require tweaking for the real data, which is why we always ask for REALISTIC sample data.

    In effect, what it's doing is adding up everything from today and earlier and subtracting that from column B.

    Can you share a more realistic copy of your data? I can troubleshoot it then. Sounds like the dates might not really be dates.
    Last edited by AliGW; 07-30-2018 at 12:23 PM.

  9. #9
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,778

    Re: Subtract inventory based on date

    I was hoping to see a data sample where my formula was not working so that I could troubleshoot it for you. Beyond what I have already said, I am afraid I really can't help without seeing what you have done.

  10. #10
    Registered User
    Join Date
    07-30-2018
    Location
    Atlanta, Georgia
    MS-Off Ver
    2018
    Posts
    11

    Re: Subtract inventory based on date

    Sorry, that was foolish wording as I try to brainstorm. I've attached the exact layout we use.
    Attached Files Attached Files

  11. #11
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,778

    Re: Subtract inventory based on date

    I can't work out what's wrong. Looking a bit more closely. Weird!

  12. #12
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,778

    Re: Subtract inventory based on date

    Well, it appears that column headers in a table are not seen as dates (they are converted to text, no matter what you do). That's the problem. You will have to use a normal range rather than a table, or define the dates in a hidden row above the table.
    Last edited by AliGW; 07-30-2018 at 01:31 PM.

  13. #13
    Registered User
    Join Date
    07-30-2018
    Location
    Atlanta, Georgia
    MS-Off Ver
    2018
    Posts
    11

    Red face Re: Subtract inventory based on date

    Thank you so much!!! Adding the dates above the table worked perfectly.

  14. #14
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Subtract inventory based on date

    How about SUMPRODUCT formula.
    See attached.

    D2 has:

    HTML Code: 
    Does this work for you?
    Attached Files Attached Files

  15. #15
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,778

    Re: Subtract inventory based on date

    So glad to have helped.

+ 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. Need Help creating Formula that will subtract from inventory
    By Eleazer2 in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 08-10-2015, 08:25 AM
  2. Replies: 3
    Last Post: 04-22-2015, 04:02 PM
  3. Replies: 2
    Last Post: 02-12-2013, 01:58 PM
  4. Excel 2007 : Subtract a cell based on current date
    By nfavours in forum Excel General
    Replies: 2
    Last Post: 11-08-2011, 06:03 PM
  5. Add/subtract a value based on date
    By jrcream in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-27-2008, 04:22 AM
  6. Subtract from inventory
    By chrispotter88 in forum Excel General
    Replies: 9
    Last Post: 01-28-2008, 09:02 AM
  7. Subtract a group of cells from a total based on ending date
    By Nicholas Scarpinato in forum Excel General
    Replies: 0
    Last Post: 05-17-2005, 11:06 AM

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