The CreatorCon Call for Content is officially open! Get started here.

Server JavaScript error Cannot find function getGuide in object com.glide.service_portal.widget.fencing.ScopedSPScriptable@11e58d3.

sana11
Kilo Guru

Hi All, I have cloned sc order guide widget for my portal in scoped application ,I am getting 'Cannot find function getGuide in object' error.

 

find_real_file.png

Is there any other alternatives for getGuide in scoped application ?

Thanks in Advance!

5 REPLIES 5

Mohit Kaushik
Mega Sage
Mega Sage

Hi Sana,

You need to check in which scope you are using it. It is not giving error as it is not present, but if the widget is in some scope and you are trying to add it to your page in some other scope then it will throw this error.

 

Please mark this answer correct if it resolved the query and mark it helpful too if it helped you at all

 

Thanks,

Mohit Kaushik

Thanks,
Mohit Kaushik
ServiceNow MVP (2023-2025)

Widget is in same scope only.

Mohit Kaushik
Mega Sage
Mega Sage

In which scope do you have your page? and in which scope you have edited the widget after cloning. 

Suppose your page is in global scope but widget was in some application scope, then when you are cloning the widget you have to clone it in the same application scope not in the global scope. After that once you finish the editing or customizing , then go to global scope and add it to your Page. It should work after this as i have also faced same kind of issue when i was trying to modify the Take survey widget in portal. The only reason of showing the OOB method not defined or not found is the cross scope of widget either at the time of cloning or at the time of adding to the page.

 

Thanks,

Mohit Kaushik

Thanks,
Mohit Kaushik
ServiceNow MVP (2023-2025)

I also cloned the sc order guide and the sc_cat_item_guide portal page in the same scope of my custom app.  Are you saying that the page should be cloned in the global scope and the widget in my custom scope? Or they should both be in the same scope?