- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-08-2020 10:27 AM
This is a followup to https://community.servicenow.com/community?id=community_question&sys_id=76c2f09edb28d410414eeeb5ca96...
I have added a Macro with Label to a catalog item and using a widget for the URL Link. The widget creates the checkbox. How to I script and capture the widget checkbox as "true" in the workflow If activity?
Currently capturing the Macro with Label variable in the IF activity not working.
answer = ifScript();
function ifScript() {
if (current.variables.var_name == 'true') {
return 'yes';
}
return 'no';
}
Example of widget from other post:
<div>
<input type="checkbox">Your Text <a href="www.google.com">To Do & not To Do</a><br>
</div>
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-08-2020 12:59 PM
Thanks all, I will go back to my original plan and use the checkbox variable and add a separate variable to display the URL LINK.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-08-2020 11:16 AM
Hello
If your issue is you want a checkbox variable's label as a link, then why you are going through the complex way, simply use the below way
As you can see, I created a checkbox variable, which's the label is "LINK", so by clicking on that you can redirect to the specified link.
UI MAcro is complex, difficult to manage and understand, and bulky to implement in the system.
If you are interested in the solution, then implement it as below
And then go to sys_properties.list>>find a property "glide.ui.escape_text" ,it is tru by defualt so mark it as false.
You requirement will get fulfill
Please Mark it helpful/correct if my answer helps in any way to resolve your query.
Reach out to me if any more help required.
Regards
Yash.K.Agrawal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-08-2020 12:59 PM
Thanks all, I will go back to my original plan and use the checkbox variable and add a separate variable to display the URL LINK.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-09-2020 12:06 AM
Hello dead blade.
As you saw in the provided suggestion ,I created a Checkbox type of field. which will work as link.
The solution is working perfectly.
So,If you tried that solution,and found correct.
then will you please mark the response as CORRECT.
It will help others,who are searching for the same kind of assistances and also help to increase my score.
I hope you got my point.
Regards,
Yash Agrawal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-16-2021 04:55 AM
Hi Yash,
This is not supported on portal, please let me know if any more modifications required.
Thanks,
Shubham