Workflows- set values activity not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
â03-19-2019 02:51 AM
Hi,
I am going through the learning plans provided by the ServiceNow developer portal.
I find it very useful and easy to follow but now I stuck at a challenge.
I have created a workflow to automate approval and task creation process.
If the approval is rejected then I set the state to "Closed Complete", this part works fine.
If the approval is given then I set the state to approved, then I create a task, wait for completion and depending on the result I either go to the end directly, or if it is 3 (Closed Complete) then I go to the same activity as after rejection to set the state to Closed Complete on the record in context.
But this last part doesn't work. When I check the actual context it shows that it was going through the right activities but the state remains Approved. So either the last set values activity was not executed or the record is not saved somehow.
But if I reject the approval then the same activity works fine, and the record is saved.
Any Idea?
Thanks.
- Labels:
-
Personal Developer Instance
-
Studio

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
â03-19-2019 07:28 AM
Hi Gergely,
SO when task completes is state not changin to CLosed completed ? If not what is the state value you see
Regards,
Harish Murikinati.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
â03-19-2019 07:34 AM
No, the problem is not with the state of the task, it is Closed Complete.
The task state is not automated, I set it to closed complete manually.
The workflow is designed to set the parent record (Needit) to closed complete too, and this is what doesn't work.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
â03-19-2019 07:55 AM
Hi Gergely,
As per the conversation i understand the workflow is running on one table and your trying to close record of another table. Please correct me if understood correctly. Based on that will tell what needs to be done.
Regards,
Harish Murikinati.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
â03-19-2019 08:04 AM
No.
Workflow is running on NeedIt and I want to set value on NeedIt.
There is another activity which creates an NeedIt Task. And after the task is completed I want to set the field on the record on which the workflow has started.
Maybe it sounds complex but it's not...
Here is the workflow: