show/hide section based on assignment group name
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-06-2023 01:16 PM
I want to make a section visible on the form based on assgn group name. Let's say I have 2 groups A and B, and two sections with same name A and B
Section A should be visible only when group A is selected, B section only when Group B is selected and so on
Section name will be same as group name. How to not hard code this so that this works even when more groups and sections (of same names) are added. Thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-06-2023 10:26 PM
@archie5 You can store the mapping of the section to Assignment group in a system property .And call the property in the script .
When new section to group mappings aligned in future just onboard the mapping to the property created above
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-10-2023 10:24 AM
Which script should I use OnChange client script? Or should it be an ajax first? Can you help me get started?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-06-2023 10:53 PM
should be an easy task.
what script did you use so far and what's not working?
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-10-2023 10:26 AM
I have used OnChange Client Script (make section visible on change of assignment group). But I have hard coded it. Looking for guidance to make it dynamic.