Access value of catalog item variable within MRVS client script
New article articles in ServiceNow Community
·
Dec 13, 2024
·
article
Sometimes there is a need to access variables defined on catalog item within MRVS client script to show/hide variables within MRVS.
You can access the variables with this syntax. This works in both Native + Portal
var applicationType = g_service_catalog.parent.getValue("variableName");
Example: I have used an onLoad catalog client script which applies to MRVS and it gave me the value of outside variable when the MRVS form was loaded.
Client Script:
Output in Native:
Output in Portal:
View original source
https://www.servicenow.com/community/workflow-automation-articles/access-value-of-catalog-item-variable-within-mrvs-client-script/ta-p/3126980
Ankur Bawiskar