Form Section
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday - last edited yesterday
Is it possible to unLink a form section from a view in incident table, without deleting the record from sys_ui_form_section. The section doesn't has a name, can it be done with sysID.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Hello @George_1,
Yes, and the trick is to stop trying to solve this at the sys_ui_form_section level entirely. Removing a section through Form Layout or Section Designer is what deletes that view's sys_ui_form_section row, which is exactly the side effect you're trying to dodge. Hide it one layer up instead, at the UI Policy level, and the record stays untouched.
- UI Policy: create one against Incident, uncheck Global, and set the View field to the specific view you want the section gone from (leave View blank if you actually mean the Default view, it won't show as a pickable option).
- UI Policy Action: add a row that targets the section itself rather than a field, and set Visible to false. No condition script needed if it should always be hidden on that view.
- Script alternative: g_form.setSectionDisplay('section_name', false) does the same thing if you want it scriptable, just watch the naming, it's the section label lower-cased with spaces collapsed after the first underscore.
- sys_ui_form_section: leave it alone. It still owns the section's position for that view, the policy just controls whether it renders.
Worth knowing too: if that same sys_ui_section is shared across more than one view, deleting or editing it from one view's layout can ripple into the others, so the UI Policy route sidesteps that risk as a bonus.
Thank you,
Vikram Karety
Octigo Solutions INC
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Hi @George_1
I don't think so. Ybelieve you can hide all the fields under section
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
https://www.servicenow.com/community/developer-forum/show-hide-form-sections/m-p/2148225
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
****************************************************************************************************************