Need a multi select variable on catalog item.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-10-2025 10:53 PM
I have the following requirement for my catalog item.
First requirement:
1) Need to create a variable "abc" with 4 option "1", "2", "3" and "4".
2) User should be able to select more than one value from the option.
Second requirement:
Need to add a text on catalog item, saying "xyz" and if user click on that I want to do certail action through script.
How can I do that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-10-2025 11:03 PM
Hi @HrishabhKumar ,
To create a variable with multiple selectable options, please follow:
- This is the most common and robust method for allowing users to select multiple items from a list.
- It presents a "slushbucket" interface, with available items on one side and selected items on the other, allowing users to move items between the two lists.
- To configure a List Collector:
- Create a variable of type "List Collector".
Specify the "Table Name" from which the options will be populated
- Optionally, add a "Reference Qualifier" to filter the available options.
- Optionally, add a "Reference Qualifier" to filter the available options.
- For a smaller, fixed set of choices, individual checkbox variables can be used.
- Each checkbox represents a distinct option, and users can select multiple checkboxes independently.
- To implement:
- Create multiple variables of type "Checkbox".
- Assign a clear label to each checkbox representing the choice.
- While not a single variable for multiple selections, MRVS can be used in conjunction with other variable types to collect multiple sets of related data.
- For example, you could have a List Collector to select multiple items, and then an MRVS to gather specific details for each selected item in separate rows.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-10-2025 11:05 PM
Hi @HrishabhKumar ,
For your second question:
if (isLoading || newValue === '') {
return;
}
if (newValue === 'your_value') { // Replace 'your_value' with the actual value that triggers the message
g_form.showFieldMsg('variable_name', 'Your message here.', 'info'); // 'variable_name' is the name of the variable, 'info' can be 'error', 'warning', etc.
} else {
g_form.hideFieldMsg('variable_name'); // Hide the message if the condition is no longer met
}
}
if (isLoading || newValue === '') {
return;
}
if (newValue === 'another_value') { // Replace 'another_value' with the actual value that triggers the message
g_form.addInfoMessage('This is an important info message.');
}
}
if (isLoading || newValue === '') {
return;
}
if (newValue === 'trigger_alert') { // Replace 'trigger_alert' with the actual value that triggers the alert
alert('You have selected a specific option!');
}
}
Please mark reply as Helpful/Correct, if applicable. Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!
Thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-10-2025 11:06 PM
Hi @HrishabhKumar
For the first requirement, use checkbox variables. Alternatively, if you have a custom table to store reusable catalog variable options, store the values in that table and use a list collector variable in the form to allow users to select multiple values. If not, create dropdown options in the 'question_choice' table and use a reference qualifier to fetch them in your list collector variable.
For the second requirement, consider using a 'Custom' type variable. Since the objective of the second requirement is unclear, it's difficult to suggest a specific solution.
Regards,
Siva