Back to Devexpress

AccordionControl.ExpandMode Property

wpf-devexpress-dot-xpf-dot-accordion-dot-accordioncontrol-0afc8438.md

latest2.8 KB
Original Source

AccordionControl.ExpandMode Property

Gets or sets a value that indicates whether an end-user can expand multiple items. This is a dependency property.

Namespace : DevExpress.Xpf.Accordion

Assembly : DevExpress.Xpf.Accordion.v25.2.dll

NuGet Package : DevExpress.Wpf.Accordion

Declaration

csharp
public ExpandMode ExpandMode { get; set; }
vb
Public Property ExpandMode As ExpandMode

Property Value

TypeDescription
ExpandMode

An ExpandMode enumeration value.

|

Available values:

NameDescription
MultipleOrNone

Any number of accordion items can be expanded.

| | Multiple |

At least one accordion item is always expanded.

| | SingleOrNone |

A single accordion item can be expanded.

| | Single |

A single accordion item is always expanded.

|

Remarks

The AccordionControl supports different expanding modes. Use the ExpandMode property to specify the mode:

ModeDescription
ExpandMode.MultipleEnd-users can expand multiple items. At least one item is always expanded.
ExpandMode.MultipleOrNoneEnd-users can expand multiple items. Collapsing all items is also possible.
ExpandMode.SingleOne accordion item is always expanded. End-users cannot collapse the expanded item.
ExpandMode.SingleOrNoneEnd-users can expand one accordion item at a time. Collapsing all items is also possible.

The following code sample demonstrates the AccordionControl in Single expanding mode:

xaml
<dxa:AccordionControl ExpandMode="Single"> ... </dxa:AccordionControl>

The image below shows the result:

Refer to the Expanding and Collapsing topic to learn more.

See Also

AccordionControl Class

AccordionControl Members

DevExpress.Xpf.Accordion Namespace