How to get sys_id for record after g_form.submit()?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2025 02:38 AM
The sc_cat_item page on service portals allow users to submit a catalog item.
I am going through the code on the widget and it seems like the submit button calls g_form.submit() to produce the record.
How can I get the sys_id of the record if g_form.submit() is successful? I need to retrieve it in the same widget, preferably in the same function that calls g_form.submit().
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2025 02:44 AM
the RITM sysId is not available until the catalog item is submitted.
what's your business requirement?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2025 02:49 AM
Business requirement is to know the sys_id of the record generated by pressing the submit button on the sc_cat_item page.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2025 03:04 AM
what's the purpose of getting that sysId?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2025 03:20 AM
Need it for a third party integration for attachments.