Why doesn 't this work? All I want to do is open a new tab for a new Case record. When I click the b
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2025 08:32 AM
All I want to do is open a new tab for a new Case record. When I click the button nothing happens and nothing shows up in the error log:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2025 09:00 AM
the view you are when form opens should have parent field in it's form view
Also update as this
function onClick(g_form) {
g_aw.openRecord("sn_customerservice_case", "-1", {
query: "parent=" + g_form.getValue('parent')
});
// use this if you want the current case to be parent of the new one
/* g_aw.openRecord("sn_customerservice_case", "-1", {
query: "parent=" + g_form.getUniqueValue()
});
*/
}
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2025 07:01 PM
Hope you are doing good.
Did my reply answer your question?
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
