<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: calling script include in the ui action in Community Central forum</title>
    <link>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3368867#M4469</link>
    <description>&lt;P&gt;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/588162"&gt;@Praju_123&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Your syntax for script include is wrong.&lt;/P&gt;
&lt;P&gt;Since your script include is in scoped app system automatically adds global keyword&lt;/P&gt;
&lt;P&gt;Seems you copied the script and forgot to update that&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AnkurBawiskar_0-1756878400598.png" style="width: 400px;"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/466985iA726975D4258F87A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AnkurBawiskar_0-1756878400598.png" alt="AnkurBawiskar_0-1756878400598.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If my response helped please mark it correct and close the thread so that it benefits future readers.&lt;/P&gt;</description>
    <pubDate>Wed, 03 Sep 2025 05:46:49 GMT</pubDate>
    <dc:creator>Ankur Bawiskar</dc:creator>
    <dc:date>2025-09-03T05:46:49Z</dc:date>
    <item>
      <title>calling script include in the ui action</title>
      <link>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3368835#M4467</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I have created a client-callable Script Include and I'm trying to call it from a client-side UI Action. However, the Script Include is not being triggered when I execute the UI Action. I'm attaching the Script Include code, UI Action code, and screenshots. Please help me fix the issue.&lt;/SPAN&gt;&lt;BR /&gt;script include:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Praju_123_0-1756874332952.png" style="width: 400px;"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/466977i8F8B873265D9F31C/image-size/medium/is-moderation-mode/true?v=v2&amp;amp;px=400" role="button" title="Praju_123_0-1756874332952.png" alt="Praju_123_0-1756874332952.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;code:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;var&lt;/SPAN&gt; &lt;SPAN&gt;BotaoDeletar&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;Class&lt;/SPAN&gt;&lt;SPAN&gt;.create();&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;BotaoDeletar&lt;/SPAN&gt;&lt;SPAN&gt;.prototype = &lt;/SPAN&gt;&lt;SPAN&gt;Object&lt;/SPAN&gt;&lt;SPAN&gt;.extendsObject(&lt;/SPAN&gt;&lt;SPAN&gt;AbstractAjaxProcessor&lt;/SPAN&gt;&lt;SPAN&gt;, {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; testing: &lt;/SPAN&gt;&lt;SPAN&gt;function&lt;/SPAN&gt;&lt;SPAN&gt;() {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;return&lt;/SPAN&gt; &lt;SPAN&gt;25&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; }, &lt;/SPAN&gt;&lt;SPAN&gt;// just for testing purpose&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; type: &lt;/SPAN&gt;&lt;SPAN&gt;'BotaoDeletar'&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;});&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;ui Action:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Praju_123_1-1756874385114.png" style="width: 400px;"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/466978iC6A2D2A5ECC7D8B8/image-size/medium/is-moderation-mode/true?v=v2&amp;amp;px=400" role="button" title="Praju_123_1-1756874385114.png" alt="Praju_123_1-1756874385114.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Praju_123_2-1756874402672.png" style="width: 400px;"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/466979iE6E0FC5DC7E26964/image-size/medium/is-moderation-mode/true?v=v2&amp;amp;px=400" role="button" title="Praju_123_2-1756874402672.png" alt="Praju_123_2-1756874402672.png" /&gt;&lt;/span&gt;&lt;P&gt;code:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;function&lt;/SPAN&gt;&lt;SPAN&gt; callScriptInclude() {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;var&lt;/SPAN&gt;&lt;SPAN&gt; foo = &lt;/SPAN&gt;&lt;SPAN&gt;new&lt;/SPAN&gt; &lt;SPAN&gt;GlideAjax&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'x_icpa_cargo_for_0.BotaoDeletar'&lt;/SPAN&gt;&lt;SPAN&gt;); &lt;/SPAN&gt;&lt;SPAN&gt;// "scope"."script include name"&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; foo.addParam(&lt;/SPAN&gt;&lt;SPAN&gt;'sysparm_name'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'testing'&lt;/SPAN&gt;&lt;SPAN&gt;); &lt;/SPAN&gt;&lt;SPAN&gt;// obligatory, to call the function by its name&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; foo.getXMLAnswer(&lt;/SPAN&gt;&lt;SPAN&gt;function&lt;/SPAN&gt;&lt;SPAN&gt;(tobeused) { &lt;/SPAN&gt;&lt;SPAN&gt;// "tobeused"- name a variable to catch the response&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; alert(&lt;/SPAN&gt;&lt;SPAN&gt;'SCRIPT INCLUDE RETURN IS '&lt;/SPAN&gt;&lt;SPAN&gt; + tobeused); &lt;/SPAN&gt;&lt;SPAN&gt;// alert opens a pop-up&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; });&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 03 Sep 2025 04:49:17 GMT</pubDate>
      <guid>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3368835#M4467</guid>
      <dc:creator>Praju_123</dc:creator>
      <dc:date>2025-09-03T04:49:17Z</dc:date>
    </item>
    <item>
      <title>Re: calling script include in the ui action</title>
      <link>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3368852#M4468</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/588162"&gt;@Praju_123&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;update your script include&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var BotaoDeletar = Class.create();
BotaoDeletar.prototype = Object.extendsObject(global.AbstractAjaxProcessor, {
	testing: function() {
        return 25;
    }, // just for testing purpose
    type: 'BotaoDeletar'
});&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;you have to use global.AbstractAjaxProcessor since it's not in global scope&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Please mark my answer as&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;&lt;FONT color="#008000"&gt;helpful/correct&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/STRONG&gt;if it resolves your query.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;I&gt;Regards,&lt;BR /&gt;Chaitanya&lt;/I&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 03 Sep 2025 05:27:27 GMT</pubDate>
      <guid>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3368852#M4468</guid>
      <dc:creator>Chaitanya ILCR</dc:creator>
      <dc:date>2025-09-03T05:27:27Z</dc:date>
    </item>
    <item>
      <title>Re: calling script include in the ui action</title>
      <link>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3368867#M4469</link>
      <description>&lt;P&gt;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/588162"&gt;@Praju_123&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Your syntax for script include is wrong.&lt;/P&gt;
&lt;P&gt;Since your script include is in scoped app system automatically adds global keyword&lt;/P&gt;
&lt;P&gt;Seems you copied the script and forgot to update that&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AnkurBawiskar_0-1756878400598.png" style="width: 400px;"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/466985iA726975D4258F87A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AnkurBawiskar_0-1756878400598.png" alt="AnkurBawiskar_0-1756878400598.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If my response helped please mark it correct and close the thread so that it benefits future readers.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Sep 2025 05:46:49 GMT</pubDate>
      <guid>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3368867#M4469</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2025-09-03T05:46:49Z</dc:date>
    </item>
    <item>
      <title>Re: calling script include in the ui action</title>
      <link>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3369192#M4480</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/588162"&gt;@Praju_123&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It seems like you are calling the different script include in glideAjax.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In Script Include API Name it very strage like 'x_icpa_cargo_for_().YOURSCRIPTINLCUDENAME' or 0 in place or () not sure.&lt;/P&gt;&lt;P&gt;but in your glideAjax function you are calling 'x_icpa_cargo_for_0.YOURSCRIPTINCLUDENAME'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Update your script include to&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;=Object.extendsObject(global.AbstractAjaxProcessor, {&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Maybe you can check the what is short for your application scope "Cargo-Formal Claim" then copy the name in API Name from script include and add to glideAjax. Try out on bg script first. It will show if that function is getting called or not.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;&lt;STRONG&gt;Bhimashankar H&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;-------------------------------------------------------------------------------------------------&lt;BR /&gt;If my response points you in the right directions, please consider marking it as 'Helpful' &amp;amp; 'Correct'. Thanks!&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 03 Sep 2025 11:28:29 GMT</pubDate>
      <guid>https://www.servicenow.com/community/community-central-forum/calling-script-include-in-the-ui-action/m-p/3369192#M4480</guid>
      <dc:creator>Bhimashankar H</dc:creator>
      <dc:date>2025-09-03T11:28:29Z</dc:date>
    </item>
  </channel>
</rss>

