- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-15-2020 03:16 AM
Hi all,
I have a UI Page with a function in the server side (in the Processing Code section). I need to write code in the client script section to asynchronously call the server side function. How can I do that? Thank you in advance for your help.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-16-2020 02:31 AM
Hope you are doing good.
Let me know if I have answered your question.
If so, please mark appropriate answer as correct & helpful to close the thread.
If not, please let us know if you need some more assistance.
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-15-2020 03:20 AM
The same way you would call a from a Client Script, can you give a try.
https://docs.servicenow.com/bundle/geneva-servicenow-platform/page/script/server_scripting/reference/r_ExamplesOfAsynchronousGlideAjax.html
Thanks,
Saji

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-15-2020 03:33 AM
Hi,
You can achieve this by using the glideAjax and client callable script include.
Refer below link
https://www.basicoservicenowlearning.in/2019/12/glideajax-in-servicenow.html
https://www.youtube.com/watch?v=0kbq9Puu_Lw&t=1087s
Mark it correct and helpful.
Thanks
Bhagyashri Sorte.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-15-2020 04:01 AM
Hi Mohammad,
you cannot call the function present in processing script directly from the UI page client script.
if you are using <g:ui_form> and submitting then the processing script would execute by default
please explain in detail what needs to happen
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-16-2020 01:02 AM
Thanks for your answer. It seems that it is not possible to do so. I solve my issue by calling a script include.