value changes based on the other field
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-21-2024 11:13 AM
Hi Team,
I want have two fields on form one is choice field and other is the lit collector field, based on the choice i have selected in choice field the other field which has type as list collector should show the options. I have created on change client script to achieve this i can see script is entering into the condition, but it is not reflecting options for second field which has type list collector based on the option selected from 1st field whose type is choice field.
can anyone help me on this?
thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-22-2024 10:50 AM
Well, to be able to list the options in a list collector you have to pass the sys_id of the choice, or choices, that you have in that list collector.
See if this content helps you:
https://www.servicenow.com/community/developer-blog/dynamically-set-list-collector-on-change-of-vari...
If my answer has helped with your question, please mark my answer as accepted solution and give a thumb up.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-21-2024 11:57 AM
Hi @Prati2 ,
I am working on a similar requirement as you are , please refer below post :
Please mark helpful/correct if my response helped you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-21-2024 01:27 PM
did not get this. do you have any other solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-22-2024 12:53 PM
@Prati2 Basically list collector stores the sys_ids of the record , so to set values in a list collector variable you need to have the sys_ids of the record , you can not simply add a value to the list collector.