how to get the value of item_option_new.name

littlelingling0
Tera Contributor

Dear All,

I would like to know how can I get the value of item_option_new.name? I want to get the Date (Question: Employee Start Date).

Screen Shot 2017-10-11 at 17.21.00.png

Screen Shot 2017-10-11 at 17.37.29.png

Thanks.

Best regards,

Ling

1 ACCEPTED SOLUTION

Hi Ling,



Yes it will give you the Text for the Question of the variable.



i.e. it will give values such as 'Employee Start Date', 'Employee's Name', 'Employee Team'



Mark Correct if this solves your issue and also hit Like and Helpful if you find my response worthy based on the impact.


Thanks


Ankur


Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

View solution in original post

6 REPLIES 6

Harsh Vardhan
Giga Patron

Hi Sin,



Please refer the thread blow.



Where catalog variable's value are stored ?


Kannan Nadar
Tera Guru

Hi,



var set = new GlideappVariablePoolQuestionSet();


set.setRequestID('23432ec74f6103008fb73ce18110c792');


set.load();


var vs = set.getFlatQuestions();


for (var i = 0; i < vs.size(); i++) {


gs.print(vs.get(i).getName());


}



use the above script and pass in the sys_id of your request item.