Skip to content

Latest commit

 

History

History
37 lines (28 loc) · 1.52 KB

commandbar_primarycommands.md

File metadata and controls

37 lines (28 loc) · 1.52 KB
-api-id -api-type
P:Microsoft.UI.Xaml.Controls.CommandBar.PrimaryCommands
winrt property

Microsoft.UI.Xaml.Controls.CommandBar.PrimaryCommands

-description

Gets the collection of primary command elements for the CommandBar.

-xaml-syntax

<CommandBar>
    <CommandBar.PrimaryCommands>
      commandBarElements
    </CommandBar.PrimaryCommands>
</CommandBar>

-xaml-values

commandBarElements
commandBarElementsOne or more object elements for classes that implement ICommandBarElement. These are typically AppBarButton, AppBarToggleButton or AppBarSeparator elements.
## -property-value The collection of primary command elements for the [CommandBar](commandbar.md). The default is an empty collection.

-remarks

The PrimaryCommands collection can contain only AppBarButton, AppBarToggleButton, or AppBarSeparator command elements. The primary commands are shown on the right side of the CommandBar, to the left of the More button (...) when the FlowDirection is LeftToRight. The layout is reversed when the FlowDirection is RightToLeft.

-examples

-see-also

SecondaryCommands