Current.variables not working in the workflow for order guide

Datta Pisal1
Tera Contributor

Hi All,

 

I have one checkbox filed called ' it_resource' on an order guide and that filed I am using in workflow script, for that i am using' current.variables.it_resource' but it is not working it. I tried to log this value then it is giving me undefined.

could you please help me solve this. 

 

Regards,

Datta

2 REPLIES 2

Ankur Bawiskar
Tera Patron
Tera Patron

@Datta Pisal1 

check this link

How to access Order Guide variables for use in Order Guide script 

If my response helped please mark it correct and close the thread so that it benefits future readers.

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

Runjay Patel
Giga Sage

Hi @Datta Pisal1 ,

 

try something like below.

var it_resource;
var gr=new GlideRecord('sc_req_item');
gr. addQuery('request', current);
gr.query();
if(gr.next()){
        it_resource=gr.variables.it_resource;
}

 

-------------------------------------------------------------------------

If you found my response helpful, please consider selecting "Accept as Solution" and marking it as "Helpful." This not only supports me but also benefits the community.


Regards
Runjay Patel - ServiceNow Solution Architect
YouTube: https://www.youtube.com/@RunjayP
LinkedIn: https://www.linkedin.com/in/runjay

-------------------------------------------------------------------------

Part 2. In this video i have talked about overview on ServiceNow platform/tool. How you can opt for personal dev instance (PDI)? how to login in ServiceNow instance and navigation to OOB modules. For document please visit: https://servicenowwithrunjay.com/ Follow Facebook page for latest update on