+ Reply to Thread
Results 1 to 24 of 24

Calculate Turn Around Time and SLA

  1. #1
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Question Calculate Turn Around Time and SLA

    Hi All,

    I want to calculate Turn Around time and SLA for making Tracker. So required VBA Code for this, so please help me.

    Below is the Details:

    Shift Start Time: 08:00
    Shift End Time: 17:00

    Worktype TAT Start Time Turn Around Time Completed Time SLA
    ABC 2 Hours 28-07-2017 08:18 28-07-2017 10:18 28-07-2017 09:25 How Much Time taken to complete this
    BCD 4 Hours 28-07-2017 08:18 28-07-2017 12:18 28-07-2017 13:32 How Much Time taken to complete this
    CDE 2 Days 28-07-2017 08:18 01-08-2017 12:18 31-07-2017 10:48 How Much Time taken to complete this

    Want to Automate Turn Around Time and SLA Coloumns,

    Also want to highlight SLA cells if its went out of Service Level.

    So please help
    Attached Files Attached Files
    Last edited by Dnyan; 07-31-2017 at 11:14 AM.

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Calculate Turn Around Time and SLA

    Please upload a workbook or a representative cut down copy, anonymised if necessary. It is always easier to advise if we can see your request in its context.

    Show a before and after situation with manually calculated results, explaining which information is data and which is results, and if it's not blindingly obvious how you have arrived at your results some explanatory notes as well.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Thank you for your help, I have attached my file, so please help me with the same
    Last edited by Dnyan; 07-28-2017 at 07:57 AM.

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Calculate Turn Around Time and SLA

    Change B6:B8 so that they contain the number of hours. i.e. 2,4,48

    Then in D6 copied down

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    although I don't see how you get 1/8/2017 at 12:18 for D6 and in F6 (for number of hours copied down)
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Thank you very much for your help, however one more condition is there
    it should Exclude Weekends (Saturday & Sunday) in Turn Around Time.

  6. #6
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Can anyone help me for this?

  7. #7
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2505 (Windows 11 Home 24H2 64-bit)
    Posts
    91,155

    Re: Calculate Turn Around Time and SLA

    In D6 copied down:

    =C6+IF(ISERROR(FIND("Hours",B6)),LEFT(B6,FIND(" ",B6)-1),LEFT(B6,FIND(" ",B6)-1)/24)

    In F6 copied down:

    =IF(ISERROR(FIND("Hours",B6)),NETWORKDAYS.INTL(C6,E6,1)&" Days",ROUND((E6-C6)*24,2)&" Hours")
    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. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  8. #8
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Thank you very much for your reply.

    However In D8 calculation date is coming as 30/07/2017 however it should be excluding Weekends (Saturday & Sunday) i.e. 01/08/2017. So please check

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

    Re: Calculate Turn Around Time and SLA

    In D6 copied down:

    =IF(ISERROR(FIND("Hours",B6)),WORKDAY.INTL(C6,LEFT(B6,FIND(" ",B6)-1),"0000011")+HOUR(C6)/24+MINUTE(C6)/1440,C6+LEFT(B6,FIND(" ",B6)-1)/24)

  10. #10
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Calculate Turn Around Time and SLA

    Quote Originally Posted by Dnyan View Post
    Thank you very much for your help, however one more condition is there
    it should Exclude Weekends (Saturday & Sunday) in Turn Around Time.
    Since you hadn't mentioned excluding weekends that was why I flagged up that there was a discrepancy with your D8 cell.

    So change the formula I gave you for D6 to
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    and copy down.

  11. #11
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Quote Originally Posted by Richard Buttrey View Post
    Since you hadn't mentioned excluding weekends that was why I flagged up that there was a discrepancy with your D8 cell.

    So change the formula I gave you for D6 to
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    and copy down.
    Thank you very much Sir, However need calculation without considering Completed time. we want Turn around time before completed the task.

  12. #12
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Quote Originally Posted by AliGW View Post
    In D6 copied down:

    =IF(ISERROR(FIND("Hours",B6)),WORKDAY.INTL(C6,LEFT(B6,FIND(" ",B6)-1),"0000011")+HOUR(C6)/24+MINUTE(C6)/1440,C6+LEFT(B6,FIND(" ",B6)-1)/24)
    Thank you very much, however Still its coming as 30/07/2017 for 48 Hours. it should be 01/08/2017 (Excluding Saturday & Sunday).

  13. #13
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Quote Originally Posted by AliGW View Post
    In D6 copied down:

    =C6+IF(ISERROR(FIND("Hours",B6)),LEFT(B6,FIND(" ",B6)-1),LEFT(B6,FIND(" ",B6)-1)/24)

    In F6 copied down:

    =IF(ISERROR(FIND("Hours",B6)),NETWORKDAYS.INTL(C6,E6,1)&" Days",ROUND((E6-C6)*24,2)&" Hours")
    Thank you,however F6 also need SLA time without Weekends.

  14. #14
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2505 (Windows 11 Home 24H2 64-bit)
    Posts
    91,155

    Re: Calculate Turn Around Time and SLA

    It's working here on your data. Working file attached.
    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 (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2505 (Windows 11 Home 24H2 64-bit)
    Posts
    91,155

    Re: Calculate Turn Around Time and SLA

    Quote Originally Posted by Dnyan View Post
    Thank you,however F6 also need SLA time without Weekends.
    Try and work it out from what you have been given. Let us know how you get on.

    In any case, how can it? You have a weekend completion date in E8!

  16. #16
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Calculate Turn Around Time and SLA

    In D8 try

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  17. #17
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Quote Originally Posted by AliGW View Post
    Try and work it out from what you have been given. Let us know how you get on.

    In any case, how can it? You have a weekend completion date in E8!
    Thank you very much AliGW, Its perfect what I was looking for. Thanks a lot again.

  18. #18
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2505 (Windows 11 Home 24H2 64-bit)
    Posts
    91,155

    Re: Calculate Turn Around Time and SLA

    You're welcome!

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

  19. #19
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Quote Originally Posted by AliGW View Post
    You're welcome!

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.
    Thank you very much, sorry for again. Again I am facing some issue in Time

    in the SLA tab Hours should Calculate only between Shift Time i.e. (08:00 to 17:00)
    If Task completed within 24 hours then it should be show in Time Format. In this case Time should be 3 Hours

    I have attached Excel file again so Please check attached excel file I have mentioned in file also that how should be calculate it.

  20. #20
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2505 (Windows 11 Home 24H2 64-bit)
    Posts
    91,155

    Re: Calculate Turn Around Time and SLA

    You keep adding requirements - how can any of us have known this? We are not mind-readers! Before I have a look, are there any other requirements you are suddenly going to remember you forgot to tell us at the start?

  21. #21
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2505 (Windows 11 Home 24H2 64-bit)
    Posts
    91,155

    Re: Calculate Turn Around Time and SLA

    Having had a quick look at your workbook, this has now become too complex for me. Maybe someone else will be able to look at it for you. I think you might be right after all that it does need some VBA.

  22. #22
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Okay, thank you very much for your cooperation, However when I entered my data in the file then only I realize that there is a problem.
    Thanks again for your help.

  23. #23
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Calculate Turn Around Time and SLA

    Quote Originally Posted by Dnyan View Post
    Okay, thank you very much for your cooperation, However when I entered my data in the file then only I realize that there is a problem.
    Thanks again for your help.
    ...and what is the nature of that problem? I suspect you are now wanting to modify the previous formulae you've been given to take account of start and end times, although at the moment I have no idea how you might want to reflect work outside those hours.

    As a minimum with these things we generally need to see what results you expect, along with notes as to how you calculate them so that we know the end goal.

    Experience tells me that the best way of doing this type of thing is to creep up on the solution gradually. So in this case I suggest you identify the formulae that will give you the results you expect assuming the working day hours DON'T apply. Once you have established that and the formula is good for all combinations of dates/times then what I normally do is add helper column(s) that work out what the affect of the daily start/end times should be and then add or subtract the helper column calculation as necessary. I've no idea how you expect to handle start/end times outside the 08:00 - 17:00 day but hopefully you do.

    Be particularly careful with start/end times that straddle midnight since deducting the start time from an end time will result in a negative number of hours and you'll need to add a +24 constant to a get the elapsed time.

  24. #24
    Forum Contributor
    Join Date
    07-22-2011
    Location
    Mumbai
    MS-Off Ver
    Excel 2007
    Posts
    185

    Re: Calculate Turn Around Time and SLA

    Thank you very much for Help, I got correct formula for this.

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    I Put this formula in D6 Cell and it gives me proper Answer which I was searching for.

    Thanks again

+ 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 calculate turn-around time and target
    By DTYS in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-12-2017, 05:21 AM
  2. [SOLVED] I need a Cell on one sheet so only calculate once, then turn into an unchanging value
    By bromanbdc in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 12-26-2016, 04:17 PM
  3. 90 day calculate and turn red
    By cmccabe in forum Excel General
    Replies: 3
    Last Post: 06-26-2014, 02:53 PM
  4. Replies: 2
    Last Post: 10-11-2012, 02:54 AM
  5. Calculate Turn Around Times
    By PJSR in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 09-19-2007, 12:16 PM
  6. Turn off calculate event
    By nobbyknownowt in forum Excel General
    Replies: 4
    Last Post: 07-05-2006, 08:35 AM
  7. how turn off calculate links?
    By Ian Elliott in forum Excel General
    Replies: 0
    Last Post: 02-24-2006, 12:45 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