Devexpress LookupEditRepositoryItem keep dropdown open while typing

327 Views Asked by At

I need to assign LookupEditRepositoryItem to GridViewColumn and keep open its' DropDown open while user types text. During typing, I need to query database and fill LookupEdit's DataSource with returned dataset. Unfortunately LookupEdit does not allow DropDown to be in open state while typing?

May be there is workaround? any special event for that?

Thanks for your time.

2

There are 2 best solutions below

0
On

Starting with version 19.2, LookUpEdit supports the AutoSuggest mode - when a user types in text, the editor fires the AutoSuggest event that runs a custom asynchronous task. This task performs a search against the given data set, and returns the ICollection object with records that match the entered text.

private void lookUpEdit1_AutoSuggest(object sender, DevExpress.XtraEditors.Controls.LookUpEditAutoSuggestEventArgs e) {
            e.QuerySuggestions = Task.Run(() => GetData());
        }
0
On

Consider creation of a custom LookUpEdit as shown in the How to implement an editor with a dynamic autocomplete list example. It allows you to provide data dynamically based on a typed value.