- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-05-2017 07:31 AM
Hi guys,
when using a variable like a "Select Box" I can retrieve with a SWITCH into a workflow all the choices available...
But while using this SWITCH function with a Yes / No variable type, it does not list automatically Yes, No as possibilities... Do you know why ?
Do I need to add a condition by right clicking on the swith and putting a condition called "yes" and another one "no" ?
OR should I need to create select box with Yes & No as choices ?
thanks a lot !
Solved! Go to Solution.
- Labels:
-
Workflow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-05-2017 09:57 AM
Can you please try with below script.
answer = ifScript();
function ifScript(){
if(current.variables.Corefa_UCM_BudgetOwner == 'Yes')
return 'yes' ;
return 'no';
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-06-2017 12:53 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-06-2017 03:20 AM
When I look at my Switch operators for Yes/No Variables, the conditions are:
activity.result == 'yes'
and
activity.result == 'no'
Kind regards,
Mark Roethof
Independent ServiceNow Consultant
10x ServiceNow MVP
---
~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field