Colleagues, a few days ago I started working with YandexCards. Not so strong in JavaScript, and in particular with callback functions ... I’d like to be simple)) I have a task to hide the labels (Point) depending on what I need to show. Made a filter for Point in ObjectManager. I turn on the filter, turn it off, everything is fine. Found here an example with a multiple choice in listBoxControl. 3rd example. Made listBoxControl, in it it is a lot of listBoxItems. I left the code up to the line "// Add a change tracking feature, if the list item is selected."
Everything suits, menus open, checkmarks are set, removed ...
Now I need to make my filter. My filter is not like in the example of "pharmacy" and "store", but by ID, where from 0-100 there are some points, from 101 to 750 others, etc. Those. I will form the string with the filter "hands", it is easier for me.
I want to know the status of the checkbox on the listBoxControl (isSelected?) ... but it’s trite to run through the listBoxItems in a loop. I can not find out their number. And therefore each will be addressed. How to implement it?