DxDropDownBox.HideDropDown() Method
Hides the editor’s drop-down window.
Namespace: DevExpress.Blazor
Assembly: DevExpress.Blazor.v24.2.dll
NuGet Package: DevExpress.Blazor
Declaration
public void HideDropDown()
Remarks
Call the HideDropDown
method to close the editor’s drop-down window.
<DxDropDownBox @bind-Value="Value" QueryDisplayText="QueryText">
<DropDownBodyTemplate>
<DxGrid @ref="Grid" SelectedDataItemChanged="@GridSelectedDataItemChanged" ... />
</DropDownBodyTemplate>
</DxDropDownBox>
@code {
// ...
void GridSelectedDataItemChanged(object item) {
DropDownBox.BeginUpdate();
DropDownBox.Value = item;
DropDownBox.HideDropDown();
DropDownBox.EndUpdate();
}
string QueryText(DropDownBoxQueryDisplayTextContext arg) {
if(arg.Value is Customer value)
return value.ContactName;
return string.Empty;
}
}
Implements
See Also