Dela via


CommandBarFlyout.SecondaryCommands Property

Definition

Gets the collection of secondary command elements for the CommandBarFlyout.

Equivalent WinUI 2 API for UWP: Microsoft.UI.Xaml.Controls.CommandBarFlyout.SecondaryCommands (for WinUI in the Windows App SDK, see the Windows App SDK namespaces).

public:
 property IObservableVector<ICommandBarElement ^> ^ SecondaryCommands { IObservableVector<ICommandBarElement ^> ^ get(); };
IObservableVector<ICommandBarElement> SecondaryCommands();
public IObservableVector<ICommandBarElement> SecondaryCommands { get; }
var iObservableVector = commandBarFlyout.secondaryCommands;
Public ReadOnly Property SecondaryCommands As IObservableVector(Of ICommandBarElement)
<CommandBarFlyout>
    <CommandBarFlyout.SecondaryCommands>
       commandBarElements
    </CommandBarFlyout.SecondaryCommands>
</CommandBarFlyout>

Property Value

The collection of secondary command elements for the CommandBarFlyout. The default is an empty collection.

Remarks

The SecondaryCommands collection can directly contain only AppBarButton, AppBarToggleButton, or AppBarSeparator command elements. Other elements must be wrapped in an AppBarElementContainer.

The secondary commands are shown in the menu portion of the flyout when the CommandBarFlyout is expanded.

Applies to

See also