Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-11-2024 04:14 AM
Hi,
I have the field u_future_date of type Date/Time and I have on before BR that execute on certain conditions. The BR need to take the current.u_future_date and add to it 2 hours. How can I achieve that?
Solved! Go to Solution.
1 ACCEPTED SOLUTION
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-11-2024 04:17 AM - edited ‎04-11-2024 04:19 AM
Hi,
Try something like this
var gdt = new GlideDateTime(current.u_future_date ); //use your field here
var hours = 60*60*2;
gdt.addSeconds(hours);
gs.log(gdt.getDisplayValue()):
-Anurag
1 REPLY 1
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-11-2024 04:17 AM - edited ‎04-11-2024 04:19 AM
Hi,
Try something like this
var gdt = new GlideDateTime(current.u_future_date ); //use your field here
var hours = 60*60*2;
gdt.addSeconds(hours);
gs.log(gdt.getDisplayValue()):
-Anurag