Skip to main content

NavigationSelectionChangedEventArgs<TInfo>.DeselectedItems Property

Returns a collection of previously selected items.

Namespace: DevExpress.Blazor.Base

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

Declaration

public IReadOnlyList<TInfo> DeselectedItems { get; }

Property Value

Type Description
IReadOnlyList<TInfo>

Previously selected items.

Remarks

The following code snippet gets previously and currently selected items:

<DxAccordion SelectionMode="NavigationSelectionMode.Single" 
             SelectionChanged="@OnSelectionChanged">
    <Items>
        <DxAccordionItem Text="Shapes">
            <Items>
                <DxAccordionItem Text="Circle" />
                <DxAccordionItem Text="Square" />
            </Items>
        </DxAccordionItem>
        <DxAccordionItem Text="Templates" />
    </Items>
</DxAccordion>

Selected item: @SelectedItem
<br /> Deselected item: @DeselectedItem

@code {
    string SelectedItem { get; set; }
    string DeselectedItem { get; set; }
    void OnSelectionChanged(AccordionSelectionChangedEventArgs e) {
        SelectedItem = e.SelectedItems.FirstOrDefault()?.Text;
        DeselectedItem = e.DeselectedItems.FirstOrDefault()?.Text;
    }
}

SelectionChanged

See Also