CommandParameter Property
Collapse the table of content
Expand the table of content

ButtonBase.CommandParameter Property

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Gets or sets the parameter to pass to the Command property.

Namespace:  System.Windows.Controls.Primitives
Assembly:  System.Windows (in System.Windows.dll)
XMLNS for XAML: Not mapped to an xmlns.

public Object CommandParameter { get; set; }
<button>
  <button.CommandParameter>
    object
  </button.CommandParameter>
</button>
<button CommandParameter="objectAsString"/>

Property Value

Type: System.Object
The parameter to pass to the Command property. The default is null.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1

Windows Phone

Show:
© 2017 Microsoft