- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-14-2024 01:08 AM
I got a requirement to make around 30 + fields are to be visible for specific conditions. Can I use the array(to store the field names) and loop condition as below with a onchange client script to set the visibility.
var fieldArray = ['field_name01', 'field_name02', 'field_name03',....................................'field_nameN'];
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-14-2024 01:12 AM - edited ‎08-14-2024 01:14 AM
Hi @Ramkumar Thanga,
You sure can. That is definitely one way to implement your requirement.
Another option (thinking out loud) could be to contain all the fields within a 'Container' if you're working with Catalog items or a form 'section' if working with a back-end form.
Using this approach you could place all the required fields within a container/section and just show/hide the container/section as required.
To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Kudos.

Thanks, Robbie
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-14-2024 01:12 AM - edited ‎08-14-2024 01:14 AM
Hi @Ramkumar Thanga,
You sure can. That is definitely one way to implement your requirement.
Another option (thinking out loud) could be to contain all the fields within a 'Container' if you're working with Catalog items or a form 'section' if working with a back-end form.
Using this approach you could place all the required fields within a container/section and just show/hide the container/section as required.
To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Kudos.

Thanks, Robbie
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-14-2024 01:39 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-14-2024 01:54 AM
Hi @Ramkumar Thanga,
Have you built a Catalog Item or Record Producer with containers and variables which you're displaying in the Portal? Theoretically, a Cat Item or Record Producer with functionality implemented with Client Scripts etc should act the same, however theory and practice are not always the same... how are you building the Portal page?
To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Kudos.

Thanks, Robbie