Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Setting the working day Post Reply Post New Topic
Author Message
Mendoza
Newbie
Newbie


Joined: 19 Mar 2010
Online Status: Offline
Posts: 8
Quote Mendoza Replybullet Topic: Setting the working day
     Posted: 19 Mar 2010 at 6:07am
Hi, I'm very new to Crystal and would appreciate some guidance.  I am trying to create a report which will highlight SLA breaches based on the subcategory type, SLA threshold relating to that subcategory and the actual time it took to resolve the call.  Hope it makes sense so far!
 
I've managed to create a report with various parameters and have placed a formula on my "ClosedDateTime" field which will highlight this field in red if the conditions laid out in the formula are met. 
 
Example:
 
if {subcategory.description}="Server" AND DateDiff("h",{request.opened_date_time},{request.closed_date_time})>1
then
( 
  {request.closed_date_time};crRed
)
Else
( 
  {request.closed_date_time};crWhite
)
 This seems to work beautifully but I have an issue, how do I specify what our working hours are?  Our support hours are between 08:00 and 18:00 therefore the SLA threshold are only valid within these hours.
 
Any pointers you can give would be great!
 
Thanks
IP IP Logged
JimNicholson
Newbie
Newbie
Avatar

Joined: 03 Dec 2009
Location: United States
Online Status: Offline
Posts: 7
Quote JimNicholson Replybullet Posted: 19 Mar 2010 at 8:41am

This should help you define your start and end time:

TimeVar SetStart := TimeValue( "8:00");      // The start of your work day
TimeVar SetEnd   := TimeValue("18:00");      // The end of your work day
TimeVar StartTime := TimeValue({Data.StartTime});//Your data Start Time
TimeVar EndTime   := TimeValue({Data.EndTime});  // Your data EndTime
IP IP Logged
Mendoza
Newbie
Newbie


Joined: 19 Mar 2010
Online Status: Offline
Posts: 8
Quote Mendoza Replybullet Posted: 22 Mar 2010 at 12:43am
Cheers Jim, will give that a go!
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum