+ Reply to Thread
Results 1 to 3 of 3

Count Amount of Days Support Received in a Set Period

Hybrid View

  1. #1
    Registered User
    Join Date
    06-24-2014
    Location
    South Wales
    MS-Off Ver
    2010
    Posts
    27

    Count Amount of Days Support Received in a Set Period

    Hi all,

    I have attached an example spreadsheet for you. This is similar to some of my other questions, but need to count days rather than items.

    The spreadsheet is a schedule for support hours given to individuals in a (on the whole) 28 day period; the period start date is shown in B6, and the end date is in F6 (these are taken from the second worksheet, 16-17 pay period dates). Column D (from row 13 down) shows the date an individual originally started support; this could be two years ago, or a few days into the period (see above). Added to this, we also have a possible end date (e13 downwards). The end date will only be entered if it is within the period dates (i.e. you won't get an end date entered that is in the future, or from the previous period). If no date is entered, it will automatically enter (and hide) the day after the end of the period, enabling the formula to work (see formula and conditional formatting in cell E13 onwards where there is no date entered).

    What I need to work out is a formula that will tell me how many days support an individual has recevied in the relevant period (result in I13 onwards). So for example, if the period is 1st April to 1st May, and someone doesn't start till 30th April, I need the resulting days received to show as 2 (up to and including the end date); this in itself is easy, I just enter =(+E16-D16)+1. However, start dates can be before the period start date, so if I use this formula for someone who start date is 1/8/15 (sorry, UK date format, mean 1st August 2015!), and they don't have an end date, I get the result 276 (I14), when it should be 31! Same goes for the same person who's start date is 1st August 2015, but they ended support on 2nd April; I need to get the days result to show 2. I have also tried a sum product (I13), but this won't count days.

    Help!
    Attached Files Attached Files

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,957

    Re: Count Amount of Days Support Received in a Set Period

    In the attached spreadsheet, there are two helper columns, M & N.

    Column M has the formula: =MAX($B$6,D13) which will get you the date the service started or the start date of the period, whichever is greater.

    Column N has the formula: =MIN(G13,$F$6) which will get you the date the service ended or the end of the period whichever is less. Note: if the period is not over and you want period to date. Use TODAY() instead of $F$3.

    Use these two dates in your calculations. You may want to wrap the formula in an if statement: =If (ISBLANK(A13),"",New End - New Start)

    Somehow I managed to lose the workbook. You should be able to recreate the helper cells with the formula provided in this post.
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

  3. #3
    Registered User
    Join Date
    06-24-2014
    Location
    South Wales
    MS-Off Ver
    2010
    Posts
    27

    Re: Count Amount of Days Support Received in a Set Period

    Thanks so much! I did have an epiphany on the way home from work today that I might need to have formula hidden in other cells to work this out, but you have completly nailed it! As the quote goes "you are a gentleman (or gentlewoman) and a scholar"!

+ 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. [SOLVED] Count days in a rolling 12 month period
    By mlafrance in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 09-30-2023, 07:45 AM
  2. [SOLVED] Need to count how many days in week period, if period starts mid week?
    By mrsdeapsleap in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-18-2016, 03:29 AM
  3. Count days per month within a period
    By Cunner in forum Excel General
    Replies: 4
    Last Post: 02-03-2014, 06:12 AM
  4. Count number of days between a period
    By amurray2307 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-20-2013, 05:40 AM
  5. Replies: 7
    Last Post: 03-26-2013, 08:32 AM
  6. Replies: 6
    Last Post: 05-10-2012, 07:33 AM
  7. Replies: 1
    Last Post: 02-24-2012, 08:46 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