- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-04-2019 10:30 AM
I have a Service Catalog item with a "start date" variable.
I need the workflow associated to the catalog item to create a task 4 days after that "start date".
I would prefer to do this via scripting (which is not an area of expertise).
Any out there able to help with a script?
Solved! Go to Solution.
- Labels:
-
Service Catalog

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2019 06:34 AM
try below
var gdt = new GlideDateTime(current.variables.start_date);
gdt.addDays(4);
answer = gs.dateDiff(gs.nowDateTime(), gdt + ' 07:00:00', true);

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2019 06:34 AM
try below
var gdt = new GlideDateTime(current.variables.start_date);
gdt.addDays(4);
answer = gs.dateDiff(gs.nowDateTime(), gdt + ' 07:00:00', true);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2019 10:26 AM
The timer did not error but it also did not "pause"...
The task is still being created.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2019 11:53 AM
Thank you!
Using your suggestion I was able to get the timer to pause - if all goes to plan, the task I need should get created in 4 days!!!
Thank you again