Calling A function From an Extended Script Include

Riro1
Kilo Contributor

I already know how to call a function from an extended script include thru this:https://www.basicoservicenowlearning.in/2019/12/script-include-servicenow.html

But I just want to know if this case is possible:

1. Script Include from another scope: blank function

2. Script Include from another scope: call the function of no. 1 then do the coding.

Purpose: 

The no. 1 script include is global and I dont have authority and if I dont call a sscript include from the global, the code doesnt work so it would help me if I can do the coding in the no.2 script include.

 

2 REPLIES 2

Tom Sienkiewicz
Mega Sage

If I understand your question correctly, this is what we commonly do to e.g. use a function from another scope include, which is limited to "this scope only". 

So e.g. you have Include A, which is in scope A, and then include B, which extsends include A. The inclue B is also scope A, and it's setting is to allow "all application scopes". That way, functions from inlcude A can now also be accessed from scope B,C...etc., by calling the extending include B.

Let me know if that makes sense.

edited the reply as the original one had a mistake 😉