Hide the details section from incident form
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-14-2024 01:37 AM
Hello Experts,
Hide the details section from incident form when details section is empty .Could help me in the script part.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-14-2024 01:44 AM
@Swapnil Meshram Create OnLoad Client Script to handle:
function onLoad() {
// Get the value of the Details field
var details = g_form.getValue('u_details'); // Replace 'u_details' with the actual field name for Details
// Check if Details field is empty
if (!details) {
// Hide the Details section if it's empty
g_form.setSectionDisplay('details_section', false); // Replace 'details_section' with the actual section name
}
}
Hit the helpful button if it solves.
✔️ If this solves your issue, please mark it as Correct.
✔️ If you found it helpful, please mark it as Helpful.
—
Shubham Jain
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-14-2024 01:56 AM
Hi @Swapnil Meshram ,
Please review the community post below, which may be helpful to you.
Solved: Re: For a Particular form view make a section's fi... - ServiceNow Community
Solved: Re: For a Particular form view make a section's fi... - ServiceNow Community
Mark Correct if this solves your issue and also mark
Helpful if you find my response worthy based on the impact.
Regards
Moin