(0) exportieren Drucken
Alle erweitern

MenuItem.StaysOpenOnClick-Eigenschaft

Gets or sets a value that indicates that the submenu in which this MenuItem is located should not close when this item is clicked.

Namespace: System.Windows.Controls
Assembly: PresentationFramework (in presentationframework.dll)
XML-Namespaces:  http://schemas.microsoft.com/winfx/2006/xaml/presentation

[BindableAttribute(true)] 
public bool StaysOpenOnClick { get; set; }
/** @property */
public boolean get_StaysOpenOnClick ()

/** @property */
public void set_StaysOpenOnClick (boolean value)

public function get StaysOpenOnClick () : boolean

public function set StaysOpenOnClick (value : boolean)

<object StaysOpenOnClick="bool" .../>

Eigenschaftenwert

Boolean value. The default value is false.

The following example uses the StaysOpenOnClick property to create an item in a submenu that does not close when the item is clicked.

<MenuItem Header="submenuitem1" StaysOpenOnClick="true" IsCheckable="true"/>

Microsoft .NET Framework 3.0 wird unter Windows Vista, Microsoft Windows XP SP2 und Windows Server 2003 SP1 unterstützt.

.NET Framework

Unterstützt in: 3.0
Anzeigen:
© 2014 Microsoft