Infragistics(R) NetAdvantage(R) : WPF 2012.1
Adding Separators between XamMenuItems
E-mail your feedback on this topic.
Shared XAML > Menus > xamMenu > Using xamMenu > Adding Separators between XamMenuItems

Glossary Item Box

Separator lines help to distinguish the different options in your xamMenu or xamContextMenu control. Adding a separator requires creating a xamMenuSeparator object and adding it to the items collection.

The following code shows you how to add separators between items in xamMenu.


<ig:XamMenu x:Name="xamMenu1" Height="25">
   <ig:XamMenuItem Header="File">
       <ig:XamMenuItem Header="New" />
       <ig:XamMenuItem Header="Open" />
       <!-- Separator line-->
       <ig:XamMenuSeparator />
       <ig:XamMenuItem Header="Exit" />

In Visual Basic:

' Add separator
Dim separator1 As New XamMenuSeparator()

In C#:

// Add separator
XamMenuSeparator separator1 = new XamMenuSeparator();

Related Topics

Binding to Data

Layout Settings

Navigating Pages Using xamMenu

Adding and Removing Items

Adding Icons to XamMenuItems

Adding Check Boxes to XamMenuItems