Does anyone know why the Listbox1.Selected(i) is not working? I copied this code from the Help app.
It is RowSelectedAt, otherwise how do you know if you are asking about a Row, Column or Cell. Typically items that take an index would end in At.
Listbox.selected was deprecated: ListBox (deprecated) — Xojo documentation
The new DesktopListbox doesn’t offer ‘Selected’ (as the error is telling in your screenshot).
How to know if your control is regular Listbox or DesktopListbox, you can check the Super:
You can use the suggestions (using TAB) to see if something that you are using is available or not. For DesktopListbx you can type ListBox1.Sele to see what options are avilable:
and see that is not what you want.
1 Like