Hi, I need to select all items in a listbox when a checkbox is clicked. Is it possible to select all items in the listbox using a single line of code? Or will I have to loop through all items and set selected to true for each one of them?
Thanks :)
Hi, I need to select all items in a listbox when a checkbox is clicked. Is it possible to select all items in the listbox using a single line of code? Or will I have to loop through all items and set selected to true for each one of them?
Thanks :)
I think you have to loop here. Selecting all items at once is a pretty specific (and probably rare) use case where it simply makes no sense to offer that functionality out of the box. Furthermore, the loop will be just two lines of code anyway.