I’m wondering if anyone else is seeing this:
WebListBox single select with DataSource, filter and search box setup.
Selecting a row sets the SelectedRowIndex properly. fires SelectionChanged event
Narrow the displayed items down with search box and filter.
Selecting a row does NOT set SelectedRowIndex, it still set to -1, fires SelectionChanged event.
Wanted to ask before filing a feedback case.
Yes, I am seeing this, but so far it has proved too complicated to generate a useful bug request as it is inconsistent. I have lodged a related bug report “65136 - Filtering Database WebListBox results in wrong selection data” with an additional comment on the other bug, where basically the SelectionChanged event fires when clicking on a line of a filtered list, but the event alleges the row = -1, even though there is obviously a selection. Sometimes the top several rows, other times the top is OK but later lines are affected; at different times the same search works fine, or not.
Have a look at feedback case: <https://xojo.com/issue/64228>
This issue is likely a result of using the example code included with Xojo (which has yet to be updated/fixed!). In your WebDataSource, you’ll have to update the SortedPrimaryKeys and RowCount methods to use the same Where Clause, specifically the ‘LIKE’ statements that you’ve applied in the RowData method. The SortedPrimaryKeys and RowCount methods in the supplied example lack the ‘%’ in the LIKE statements, so the results are different from RowData.
Thanks. Unfortunately that doesn’t seem related to this problem, as all the functions call the same function to set the SELECT statement (and in any case I use Instr not LIKE). Something ■■■■■ going on in any case.
Good lord. Did it really block out the word I just typed, which is like “queen” except ending in “r”. OFFS.