Need help on MVRS

shaik_irfan
Tera Guru

Hi,

I have Multi row variable set created now my customer want to have a pop up as a hint or a description that displays just like how we set annotation hint for variables

 

is it possible ?

1 ACCEPTED SOLUTION

Try this:

add a Catalog Client script (on the Catalog Item level) with the following:

function onLoad() {
   //Type appropriate comment here, and begin script below
   this.my_g_form = g_form;
}

 

And change your onLoad script to:

function onLoad() {
    //Type appropriate comment here, and begin script below
    if (parent.g_form) {
        g_form.addInfoMessage("message");
    }
    else if (this.my_g_form) {
        this.my_g_form.addInfoMessage("message");
    }
}

View solution in original post

17 REPLIES 17

Harsh Vardhan
Giga Patron

i am assuming you are saying you want some sort of text before the MRVS , you can try with  label type variable before the MRVS and there you can set some sort of message including some html 

 

or widget if you are on portal then use the widget before the MRVS

Namrata Khabale
Giga Guru

Hey Irfan,

Check out this, it might help you:

https://www.servicenowguru.com/scripting/client-scripts-scripting/showhide-service-catalog-variable-...

 

Mark it Correct or Helpful, if it works based on impact....!!!!

 

Best Regards,

Namrata.

Best Regards,

Namrata.

Willem
Giga Sage
Giga Sage

Try this, replace message with the message you want to show:

$scope.page.g_form().addInfoMessage(message)

 

Or

var g_form = $scope.page.g_form;
g_form.addInfoMessage(message)

@Willem 

 

For this i believe i need to clone the widget right ? and we want the text only for one catalog item. 

 

Is that possible ?