Button.Flyout property

Gets or sets the flyout associated with this button.

Syntax


public FlyoutBase Flyout { get; set; }


<Button>
  <Button.Flyout>flyout</Button.Flyout>
</Button>



<Button Flyout="{StaticResurce flyoutResourceKey"/>


XAML Values

flyout

An instance of a FlyoutBase derived class; typically Flyout or MenuFlyout.

flyoutResourceKey

The key that identifies the flyout being requested. The key refers to an existing resource in a ResourceDictionary.

Property value

Type: FlyoutBase

The flyout associated with this button, if any; otherwise, null. The default is null.

Remarks

By default, the flyout that's set as the value of the Flyout property displays when the button is tapped or otherwise invoked, you don't need to call methods to display it. That differs from the behavior of flyouts assigned through the FlyoutBase.AttachedFlyout attached property; these flyouts must be explicitly displayed by calling ShowAt on the flyout instance, or the static ShowAttachedFlyout method.

Requirements (device family)

Device family

Universal

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.UI.Xaml.Controls
Windows::UI::Xaml::Controls [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (operating system)

Minimum supported client

Windows 8.1

Minimum supported server

Windows Server 2012 R2

Minimum supported phone

Windows Phone 8.1 [Windows Runtime apps only]

Namespace

Windows.UI.Xaml.Controls
Windows::UI::Xaml::Controls [C++]

Metadata

Windows.winmd

See also

Button
Flyout
MenuFlyout
Quickstart: Adding a Flyout
XAML Flyout and MenuFlyout sample

 

 

Show:
© 2015 Microsoft