- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-09-2020 01:19 AM
Hi Team ,
Need help. I am not sure I have built a catalog item and it works fine in CSM portal but not in service portal For example the below code is not working when running from Service Portal view. The alert is not triggered but it is triggered in CSM. Can you let me know why?? This is really weird.
var k =g_form.getValue('type_of_operation');
alert(k);
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-09-2020 01:21 AM
Hi,
please set the UI type = ALL for your client script
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-09-2020 02:45 AM
It is not working. System is throwing alert but it is also allowing to submit the form something that could be prevented when we use getXMLWait along with onSubmit client script.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-09-2020 02:56 AM
Hi,
you shall call glideajax in onChange client script not in onSubmit.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-09-2020 02:57 AM
GlideAjax with Asynchronous won't work in onSubmit
Please move your code to onChange of the variable which you are trying to validate
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-09-2020 03:29 AM
I see but there are certain validation in my requirement which should be validated while form submission. Isn't there any way we can control the return in asynchronous glideajax while getXML method is fetching the value??