- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā04-15-2021 02:56 AM
Hello Community,
Can anyone help us.
We have variable set with few variables and we are this variable set for couple of catalog items,
Our case we want hide particular variable in one catalog item how to do this tried with catalog client script onload and ui policy and it's not working still visible in portal Can anyone help us with solution for this
Please note this variable is mandatory in variable set
Thanks,
Nagesh
Solved! Go to Solution.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā04-15-2021 03:25 AM
Hey! Using a catalog ui policy should be the easiest solution. Set the catalog ui policy to apply on the specific catalog item, build your condition (leave empty if it should always apply) and then use an UI policy action where you set the variable from the variable set to Mandatory -> false and Visible -> false. The other attributes can stay with "Leave alone".
This should work in Service Portal as well.
The UI policy action could look like this: (Standard Employee Questions is the variable set in this example)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā04-15-2021 03:25 AM
Hey! Using a catalog ui policy should be the easiest solution. Set the catalog ui policy to apply on the specific catalog item, build your condition (leave empty if it should always apply) and then use an UI policy action where you set the variable from the variable set to Mandatory -> false and Visible -> false. The other attributes can stay with "Leave alone".
This should work in Service Portal as well.
The UI policy action could look like this: (Standard Employee Questions is the variable set in this example)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā04-15-2021 03:34 AM
Awesome it works perfectly!!! thanks for the solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā05-02-2023 08:32 AM - edited ā05-02-2023 08:35 AM
Hi Tim, i am trying to execute this logic, i cant see variables coming under variable set like you do. I can just see the name of variable set like "Non prod application details"(this is a variable set), no other option. Any idea where i might be wrong?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā05-08-2023 01:40 AM
Judging from your screenshot, the only explanation I can think of from the top of my head would be the variable set is not yet related to the Catalog Item. You can check on the Catalog Item itself in the related lists.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā05-09-2023 05:27 AM
Or, maybe the variable set is empty!