[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
   Reporting
  [Expand]Data Grid
  [Expand]Ribbon, Bars and Menu
  [Expand]Charts Suite
  [Expand]Pivot Grid
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Expand]Layout Management
  [Expand]Windows Modern UI
  [Expand]Printing-Exporting
  [Collapse]Data Editors
    Included Components
   [Expand]Implementation Details
   [Collapse]Getting Started
    [Expand]How To: Create a Registration Form
     How to: Enable Masked Input (Text Editor)
     How to: Create a Functional ButtonEdit
     How to: Create a ComboBoxEdit and Bind it to Data
     How to: Customize a DateEdit
     How to: Create and Customize a ProgressBarEdit
     How to: Create and Customize a RangeTrackBarEdit
     How to: Create and Add Palettes in PopupColorEdit
     How to: Customize a SpinEdit to Display Currency Values
     How to: Create a SearchLookUpEdit and Bind it to Data
   [Expand]Editor Types
   [Expand]Common Features
   [Expand]Range Control
   [Expand]Visual Elements
   [Expand]End-User Capabilities
   [Expand]Examples
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Diagram Control
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
  [Expand]Scheduler (legacy)
 [Expand]Scaffolding Wizard
 [Expand]Localization
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

How to: Create a SearchLookUpEdit and Bind it to Data

The SearchLookUpEdit editor combines the functionality of the LookUpEdit with the built-in Find box feature that allows you to quickly locate data.

This document demonstrates how to create a SearchLookUpEdit control and bind it to data.

Follow the steps listed below.

Expanded Steps 1-4. Create a New Project and Add a SearchLookUpEdit

  1. Run MS Visual Studio 2010.

  2. Create a new WPF Application project. For this, choose New Project on the File menu or press Ctrl+Shift+N, and then choose the WPF Application.

  3. Add a LookUpEdit component to the project.

    To do this, open the Visual Studio toolbox, choose the LookUpEdit toolbox item and drop it onto the window.

    Note

    To apply the custom "Office2010Black" theme, manually add a reference to the DevExpress.Xpf.Core.v18.1.dll library.

  4. To enable the Find box feature, set the StyleSettings property to "SearchLookUpEditStyleSettings":

Expanded Steps 5-10. Create Data Objects

Add a data source to your WPF Application. For this, follow the steps below.

  1. Open the Data menu and click the Add New Data Source item.

  2. Choose a Database as a type of a data source.

  3. Then choose a Dataset as a Database Model.

  4. As a data source, choose the Microsoft Access Database File. As a data connection, choose the nwind database. By default, it is stored in the following path. C:\Users\Public\Documents\DevExpress Demos 18.1\Components\Data

  5. In the Tables menu, choose Customers.

  6. After this, click Finish to close the wizard.

Expanded Steps 11-13. Bind SearchLookUpEdit to Data

  1. Bind the SearchLookUpEdit to the data source. Add the following code.

    Set the ValueMember property to "CustomerID". Set the DisplayMember property to "ContactName":

  2. To disable automatic column creation, set the AutoPopulateColumns property to "False". Create required columns and bind them to corresponding data fields:
  3. Run the application to see the result.

Is this topic helpful?​​​​​​​