UI Page Scope issues

arunamshu1
Kilo Explorer

I have a UI page created in an Custom Application.

I'm trying to access the UI page via UI Action. But getting an error saying "Page does not exist".

If I create a similar page in Global Application, Then its working.

How can I make a UI Page created in an custom application accessible from a scoped application using UI action?

9 REPLIES 9

michalhancar
Mega Contributor

Hello Arunamshu,



I found the way. If you are in Global, all you can do is just use the UI page name. Example:


var gdw = new GlideDialogWindow('approve_confirmation_window');



However, because you are in a scoped application, you need to give the GlideDialogWindow full name including the scope name. Meaning - [scope prefix]+[UI page name].



So in your case:



var dialog = new GlideDialogWindow('x_temal_uitest_cat_kitkat');


dialog.render();



I had the same issue but this solved it


Michael,



You understand that this was the same response that was posted a year ago?



Thanks,


Chris


Chris,



A year ago, Arunamshu's original question was about "Page not found"



Then, he mentioned he was using the following:


var dialog = new GlideDialogWindow('x_temal_uitest_cat_kitkat.do');


to which I replied that he needs to use following:


var dialog = new GlideDialogWindow('x_temal_uitest_cat_kitkat');



Basically the same without that ".do" part because A) he is in a scoped application so only the "kitkat" name of UI page cannot be used and B) he cannot used .do because that is an endpoint, not the name of the UI page.


Michael,



I am aware.   But your response did not call that particular portion out.   You merely stated the same thing we were saying, to use the scope name as a prefix, which was quite redundant.


Chris,



my response gave an answer that solved the problem so no, it was not redundant. What you were discussing was about scope too, but then you wanted to know more information, meaning what name Arunamshu was using AND whether he can even access it at which point you provided an endpoint to him. Which obviously confused Arunamshu because he replied that he was using "x_temal_uitest_cat_kitkat.do" (endpoint) in the GlideDialogWindow constructor. It does not matter that I did not say "dont use endpoint format" or "leave out the .do part" because there are millions of possibilities for wrong input and it is ineffective to list them all. Yes, it might have solved HIS issue, but I stated how to solve the problem in an understandable fashion for everyone else who has the exact same problem.