Defer Time Miscalculating?
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
18-11-19 09:04 PM
I'm currently working through the Defer portion of section 9. When I use
I receive the wrong value. When I check the Defer time in the Control panel, I see a time five minutes ahead, but five hours ago. When I hit Evaluate Expression in the Expression Chooser it gives me the correct time, so I have no idea why Defer is appearing as five hours ago. The other DateTimes in the Control panel are the correct times, so I don't think it's a timezone issue or anything.
------------------------------
Robert Wertz
------------------------------
ToDateTime(Today() & " " & LocalTime() + MakeTimeSpan(0,0,5,0))
I receive the wrong value. When I check the Defer time in the Control panel, I see a time five minutes ahead, but five hours ago. When I hit Evaluate Expression in the Expression Chooser it gives me the correct time, so I have no idea why Defer is appearing as five hours ago. The other DateTimes in the Control panel are the correct times, so I don't think it's a timezone issue or anything.
------------------------------
Robert Wertz
------------------------------
4 REPLIES 4
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
19-11-19 01:27 PM
I believe the Defer time is calculated in UTC time which is probably why your seeing the 5 hours ago issue when you use your LocalTime(). In one of my processes where I use Defer, I calculate it by using Now() + [Hours to Defer] where [Hours to Defer] is a time span = 0.04:00:00 hours. You'll find for a lot of the time calculations in Blueprism you'll need to use UTC time as your anchor point.
------------------------------
Matt Palmer
Business Process Specialist
Chesapeake Energy
America/Chicago
------------------------------
------------------------------
Matt Palmer
Business Process Specialist
Chesapeake Energy
America/Chicago
------------------------------
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
19-11-19 09:33 PM
That was my first thought too. The fact that pressing "evaluate expression" returns the proper value is what confuses me. Plus, when I use LocalTime() in the summary field it correctly identifies the time. It's just weird that Defer is the only one of these that seems to be set in UTC and then converted back to EDT.
------------------------------
Robert Wertz
------------------------------
------------------------------
Robert Wertz
------------------------------
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
20-11-19 03:12 AM
When you calculate the Time expression using evaluate : It shows you the result in local time as per your PC TZ. However, BP stores everything in the DB in UTC TZ and thats why in control panel you would be able to see the Time in UTC (Which may be 5 hours as per your point.)
------------------------------
Vivek Goel
RPA Architect
Asia/Singapore
+6594554364
https://www.rpatools.com/
------------------------------
------------------------------
Vivek Goel
RPA Architect
Asia/Singapore
+6594554364
https://www.rpatools.com/
------------------------------
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
02-10-21 06:42 PM
Came to forums to find the answer to this question - the fact that the time didn't match the evaluate value was also my main confusion!
Thank you from two years in the future 🙂
-Colleen
------------------------------
Colleen DiVincenzo
------------------------------
Thank you from two years in the future 🙂
-Colleen
------------------------------
Colleen DiVincenzo
------------------------------
