- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-27-2025 03:39 AM
I have a client script calling script include to populate some data in form.
The client script is working in Classic UI but not working from SOW.
I have updated Desktop Type as "ALL"
I tried SOW view also.
I tested that Script include call is not working from SOW.
How to solve this..?
Other client scripts that have no script include call are working in SOW without update any view. View is Global.
Does Script Include work from SOW by
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-28-2025 12:45 AM
so what debugging did you perform in your client script.
Did you check if logs came? any browser console error when the onchange runs
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
02-28-2025 01:49 AM - edited 02-28-2025 01:50 AM
Hello @AnnuK
I have rebuilt your code. Please verify the screenshots below. Also, please cross-check the yellow highlighted area in your Client Script and Script include.
Script Include
1. In the script include, you will have to define "ID" variable as this.getParameter("sysparm_id");
2. The value of ID should be your Configuration Item.
3. Make sure cmdb_rel_ci is giving you the expected result with harcoded values before running the script
4. Isolate Script check box should be true
Result:
Thank You!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-28-2025 12:04 AM
ok, you have mentioned it works in SOW. But for me, pls check my code, it does not work in SOW.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-28-2025 01:49 AM - edited 02-28-2025 01:50 AM
Hello @AnnuK
I have rebuilt your code. Please verify the screenshots below. Also, please cross-check the yellow highlighted area in your Client Script and Script include.
Script Include
1. In the script include, you will have to define "ID" variable as this.getParameter("sysparm_id");
2. The value of ID should be your Configuration Item.
3. Make sure cmdb_rel_ci is giving you the expected result with harcoded values before running the script
4. Isolate Script check box should be true
Result:
Thank You!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-28-2025 03:21 AM
Thank you so much. I have fixed the issue.