aspnet-devexpress-dot-web-dot-aspxgridlookup-f9b84b34.md
Gets or sets a value that specifies item selection behavior.
Namespace : DevExpress.Web
Assembly : DevExpress.Web.v25.2.dll
NuGet Package : DevExpress.Web
[DefaultValue(GridLookupSelectionMode.Single)]
public GridLookupSelectionMode SelectionMode { get; set; }
<DefaultValue(GridLookupSelectionMode.Single)>
Public Property SelectionMode As GridLookupSelectionMode
| Type | Default | Description |
|---|---|---|
| GridLookupSelectionMode | Single |
One of the GridLookupSelectionMode enumeration values.
|
Available values:
| Name | Description |
|---|---|
| Single |
Only one list item can be selected at one time.
| | Multiple |
Multiple items can be selected within the editor’s dropdown list.
|
The SelectionMode property specifies how many list items (grid rows) can be selected simulateneously within the dropdown ASPxGridView control.
<dx:ASPxGridLookup ID="gridLookup" runat="server" SelectionMode="Multiple" ...>
<Columns>
<dx:GridViewCommandColumn ShowSelectCheckbox="True" SelectAllCheckboxMode="AllPages" />
<!-- ... -->
</Columns>
<!-- ... -->
</dx:ASPxGridLookup>
View Example: How to enable multiple selection
For more information about available selection modes, read the Selection Modes topic.
Note
SelectionMode property is set to Multiple), incremental filtering does not work.Note
The SelectionMode property synchronizes its value with the ASPxGridViewBehaviorSettings.AllowSelectSingleRowOnly property (which can be accessed through the GridViewProperties.SettingsBehavior property).
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the SelectionMode property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
lookupEdit.Width = Unit.Percentage(100);
lookupEdit.SelectionMode = GridLookupSelectionMode.Multiple;
lookupEdit.TextChanged += EditValueChangedHandler;
lookupEdit.Width = Unit.Percentage(100)
lookupEdit.SelectionMode = GridLookupSelectionMode.Multiple
AddHandler lookupEdit.TextChanged, AddressOf EditValueChangedHandler
See Also