+ Reply to Thread
Results 1 to 5 of 5

Excel formula to help count holiday and absence

Hybrid View

  1. #1
    Registered User
    Join Date
    01-03-2019
    Location
    UK
    MS-Off Ver
    2016
    Posts
    2

    Excel formula to help count holiday and absence

    Hi,
    What formula can I use to count holiday/absence days? i.e.
    If I have days set up in a spreadsheet and add "1H" or "0.5H" to represent 1 day of holiday and half a day of holiday, how can I get excel to sum within a range of cells (i.e. a whole month) the amount of H days booked?
    Thanks

  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 2406
    Posts
    44,662

    Re: Excel formula to help count holiday and absence

    Will you please attach a SMALL sample Excel workbook (10-20 rows of data is usually enough)? However, please give us an indication of the approximate number of rows of data you want the solution to work with (100, 1000, 100,000 or whatever). Please don't attach a picture of an Excel sheet (no-one will want to re-type all your stuff before starting).

    1. It does NOT have to be your real sheet - mock up a SAMPLE if you need to. But not 1000's of rows!!! It makes manual checking so tedious. Whatever you do... make sure that all confidential information is removed first!!

    2. Make sure that your sample data are truly REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    3. Make sure that your desired solution is also shown (mock up the results manually).

    4. Try to avoid using merged cells. They cause lots of problems!

    Unfortunately the attachment icon doesn't work at the moment. So, to attach an Excel file you have to do the following: Just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.
    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
    Valued Forum Contributor PaulSP8's Avatar
    Join Date
    11-21-2017
    Location
    Chorley, England
    MS-Off Ver
    2013 & 2021
    Posts
    437

    Re: Excel formula to help count holiday and absence

    Using A1:A31 as your "Month" then try;

    Formula: copy to clipboard
    =SUM(IF(ISNUMBER(FIND("H",$A$1:$A$31)),VALUE(LEFT($A$1:$A$31,FIND("H",$A$1:$A$31)-1)),0))


    It's an Array formula so you'll need to press CTRL, Shift and Enter instead of just Enter when you've input it, if done correctly you should see curly braces { } at either side of the Formula.

  4. #4
    Registered User
    Join Date
    01-03-2019
    Location
    UK
    MS-Off Ver
    2016
    Posts
    2

    Re: Excel formula to help count holiday and absence

    Thank you so much that is perfect! That's amazing :D
    Last edited by Ri_; 01-03-2019 at 01:41 PM.

  5. #5
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2502
    Posts
    13,700

    Re: Excel formula to help count holiday and absence

    Another way?

    Formula: copy to clipboard
    =SUMPRODUCT(--(SUBSTITUTE(UPPER(A1:A31),"H","")))
    Dave

+ 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] Formula to count "absence with permission"
    By leprince2007 in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 10-20-2018, 09:08 AM
  2. [SOLVED] How to Exclude Weekends in Employee Absence Tracker Count
    By pugz in forum Excel General
    Replies: 20
    Last Post: 07-30-2018, 03:09 AM
  3. [SOLVED] Weekend and Holiday Exclusion From Count
    By Winship in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 04-04-2017, 05:25 PM
  4. Replies: 5
    Last Post: 02-14-2017, 04:27 PM
  5. [SOLVED] Trying to count holiday taken so far
    By Merboo in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 06-24-2014, 10:28 AM
  6. Replies: 4
    Last Post: 11-08-2013, 05:01 AM
  7. Quick Excel formula question before I go on holiday tomorrow!
    By Pheasant Plucker® in forum Excel General
    Replies: 2
    Last Post: 10-05-2005, 02:05 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