Scripting a delay in a wait-for condition
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2017 08:41 AM
Hello all.
I have a wait for condition in my workflow that is supposed to look at a field and run if the field is a particular value. That field is being set by a UI action.
The problem I am having is that the wait for condition does not trigger when the UI action is pressed. If I press the UI action again, then it runs. I am strongly suspecting that the issue involves some sort of delay when the UI action is run so I would like to have the wait for condition have a delay built in before evaluating the field.
Ideas on how I can accomplish this?
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2017 01:51 PM
So it looks like the Wait For condition isn't just running once. Observe:
First of all, I added a gs.log ('current.u_reject_reason') to the wait for condition before the if.
I hit the Resubmit Schedule button twice, once at 16:46:00 and again at 16:46:54. You'll notice that after I hit the resubmit button at 16:46:00 it runs a bunch of times, and ultimately does not update because the last log shows current.u_reject_reason = schedule. Then later on, I press the button again. Only this time, the gs.log only runs once and is the correct value.
Is there a reason why the workflow is doing this the first time and not the second?
Thanks

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2017 06:27 AM
I have no additional information at this time. If nobody else offers anything, I recommend reaching out to customer support. I'll be interested to hear what they have to say.
HI Service Portal - ServiceNow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-12-2017 06:41 AM
Yes, a HI incident has been opened in response to this anomalous behaviour.
Thanks