AdvListBox - ItemIndex Problem

Hi,



1.

When the AdvListBox is not filtered and no item is selected, ListBox->ItemIndex returns -1.



However, if the AdvListBox is filtered and no item is selected, accessing ListBox->ItemIndex gives 'List index out of bounds (-1)' EListError exception instead of returning -1.



This seems to be a bug.



2.

With TListBox, I use ListBox->Items->IndexOf(as) to return the index of an item.

e.g. ListBox->ItemIndex = ListBox->Items->IndexOf(as);



Is there an equivalent function in TAdvListBox?



Thanks,

Terence

Thanks for reporting. We fixed issue 1.

There is currently not an IndexOf() function but this is an interesting suggestion and we'll add this.