how to place a variable inside a variable set

sohan_snow
Tera Contributor

Hi All,

I need to place an extra variable inside a variable set applicable ONLY for 1 catalog item. For other catalog items that uses the same variable set, this extra variable should not be displayed.

I tried keeping the order of the extra variable 'd' as 150 (order of variable 'a' and 'b' is 100 and 150 respectively ) . however, the variable 'd' was displayed below the last variable 'c' instead displaying below variable 'a'

find_real_file.png

Thanks in advance

1 ACCEPTED SOLUTION

Geoffrey2
ServiceNow Employee
ServiceNow Employee
  1. Place Variable d inside the Variable Set where you want it.
  2. Create a Catalog UI Policy on the Variable Set that hides Variable d by default (no condition).   Leave Order at 100. Make sure you can't see the Varaible on any Catalogue Item.
  3. Create a new Catalog UI Policy on the 1 Catalogue Item where you want to see it. Show Variable d. Set the Order to 110 (or anything over 100).
    Verify that you can see Variable d only on the Catalogue Item you want.

View solution in original post

12 REPLIES 12

Hi Geoffrey, Is there any way if the same can be achieved by creating the variable in the catalog item rather in the variable set


Geoffrey2
ServiceNow Employee
ServiceNow Employee

You would have to create a new UI Policy on every single other Catalogue Item to hide Variable d.


Hi Sohan,



Can you set the order of variable d in the catalog item to 125?


hi thanks for your revert, I updated the order of variable 'd' to 125,however it still was displayed at the end of the variable set i.e after variable 'c'


you cant do it, that way.



VS are grouped... you cant display a local variable within the invoked VS. Order will not help.