script include

Dizy M
Tera Expert

Hi!

 

Can smeone pls explain where to get this (the highlighted)?  Is this coming from a field in a table?? 

 

DizyM_0-1699877315612.png

I'd appreciate any help. thank you!

1 ACCEPTED SOLUTION

Shubham Singh
Mega Guru

Hi @Dizy M 

 

You can find it in Client Scripts or UI Action Scripts. Basically, if you have to pass any parameter (or data) from client-side code to server-side code, you have to use GlideAjax API to achieve it. You can pass the parameters using the addParam() method of GlideAjax API and fetch it in the Script Includes using this.getParamater() method.

 

Attaching the reference to get more idea on this:

https://www.servicenow.com/community/developer-articles/glideajax-example-cheat-sheet/ta-p/2312430

 

Thanks!

 

If my answer has helped with your question, please mark my answer as accepted solution and give a thumb up 🙂

View solution in original post

5 REPLIES 5

Jaspal Singh
Mega Patron
Mega Patron

Hi Dizy,

It has to be input from client script or some reference qualifier parameter. Can you check in Client scripts once by applying filter as Keywords | are | sysparm_sysID

yaswanthi2
Giga Sage

Hi @Dizy M 

 

this.getParameter('sysparm_sysID'): It's like asking script to give you a specific piece of information called 'sysparm_sysID'. for example if you pass some information from Client script to script include. Here will have the input received from client script

Shubham Singh
Mega Guru

Hi @Dizy M 

 

You can find it in Client Scripts or UI Action Scripts. Basically, if you have to pass any parameter (or data) from client-side code to server-side code, you have to use GlideAjax API to achieve it. You can pass the parameters using the addParam() method of GlideAjax API and fetch it in the Script Includes using this.getParamater() method.

 

Attaching the reference to get more idea on this:

https://www.servicenow.com/community/developer-articles/glideajax-example-cheat-sheet/ta-p/2312430

 

Thanks!

 

If my answer has helped with your question, please mark my answer as accepted solution and give a thumb up 🙂

Danish Bhairag2
Tera Sage
Tera Sage

Hi @Dizy M ,

 

As everyone have mentioned that most probably it should be coming from the client script or some place else. In order to easily find it you can go to the catalog client scripts table (catalog_script_client) & filter it using script contains "fetchDPandSub"

It will give u the client script in which it is being used.

 

Thanks,

Danish