Current.variables not working in the workflow for order guide
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2025 07:27 AM
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
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2025 08:09 AM
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.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2025 08:31 AM
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
-------------------------------------------------------------------------