Gets or sets the command associated with the menu item.
Assembly: PresentationFramework (in PresentationFramework.dll)
This property is used to associate a command with a particular MenuItem instance. The following example associates the Copy command with a MenuItem and automatically supplies the input gesture text Ctrl+C. The example does not set the Header property, but the Header for the MenuItem is "Copy" at run time. You can specify another header for the MenuItem if you want it to be different. For information on how to bind to the desired command, see .013d68a0-5373-4a68-bd91-5de574307370
The following examples show how to use the command property to associate commands with menu items.
<MenuItem Header="_Open" Command="ApplicationCommands.Open"/> <MenuItem Header="_Save" Command="ApplicationCommands.Save"/>
Available since 3.0