How do I access global properties from a scoped application?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-27-2020 02:32 PM
I am trying to get my instance url via script in a scoped application. However, I keep getting the following error:
com.glide.script.fencing.CrossScopeAccessNotAllowedException: Access to Glide API: properties from scope x_pnnla_siteaccess not allowed
Caused by error in <refname> at line 1
==> 1: var url = gs.getProperty('glide.servlet.uri');
2: gs.info(url);
How do I access the instance url from a scoped application?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-15-2020 02:09 AM
I need to get the UserAgent string in Script include of my project but facing cross scoped application access.
how do I access UserAgent details in cross scoped application?
below query is working in Global scope
var userAgent = '' + gs.getSession().getProperty('user-agent');
but when I am trying to access from my scoped application I am getting below error
com.glide.script.RhinoEcmaError: Cannot find function getProperty in object com.glide.script.fencing.ScopedGlideSession@10dfda2. script : Line(1) column(0) ==> 1: var userAgent = '' + gs.getSession().getProperty('user-agent'); 2: gs.log(userAgent);