
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-01-2022 08:39 AM
Hi,
Is there a way to use the synchronous glide ajax method (getXMLWait()) on OnChange() catalog client scripts for service portal ? What I found searching on community was a "trick" to use getXMLWait() on OnSubmit() catalog client scripts for service portal -> https://www.servicenow.com/community/developer-articles/getxmlwait-alternative-for-service-portal/ta... but I didn't found anything about use on OnChange().
Can you help me ?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-01-2022 10:02 AM
Hello,
Then as suggested In the onsubmit client script just check if the field is still empty if yes return false else return true.
Please mark my answer as correct based on Impact.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-01-2022 09:12 AM
Hello,
Just wondering why you are not using getXML() on the Onchange client script as the form is not being submitted os it does not really have to wait?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-01-2022 09:23 AM
Currently I am using getXML() on the script, but the problem is that I don't want that the users have the possibility to submit the form while my OnChange() catalog client script is running. So I have the ideia to use the getXMLWait() to "block" the another users actions until my OnChange() script runs
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-01-2022 09:37 AM
Is the getXMLWait() not working in onchange client script. I believe it should work?
Interesting. Make the field which you are populating mandatory? will that not do the trick as with out any value in that field it user will not be able to submit?
OR
In the onsubmit client script just check if the field is still empty if yes return false else return true.
Let me know what you think of the above.
Please mark my answer as correct based on Impact.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-01-2022 09:46 AM
I tried to use getXMLWait(), but seems that this method doesn't work on Service Portal.
The variables of the form are already mandatory, but I still face the same issue.