hclleapforum

Open full view…

How to know which options were selected on a "Select Many" item?

technologirl
Thu, 16 Jan 2020 20:53:14 GMT

with Js

christopher_dawes
Thu, 16 Jan 2020 23:28:25 GMT

The selected options of a select many are in the value. If you had a list of red, green, blue, yellow and purple and red and green are selected then the value would be "red__#__green". So to know what is selected in js you would do something like this: var selected = BO.F_SelectMany.getValue(); var selArr = selected.split("__#__"); Now I have an array with the options that were selected and I can use them anyway I like in my following code.

christopher_dawes
Fri, 17 Jan 2020 15:44:13 GMT

I can see the post is a bit messed up. The values are delimited by underscore underscore pound underscore underscore.