I have a WPF application that contains a datagrid. It is bound to my List object \"Orders\" shown below.
public class OrderBlock
{
public Settings setting;
We can do this in two ways,
a) By using Dependency property b) By adding System.Windows.Interactivity.dll.
Usually I prefer second way.
step 1: Implement ICommand interface in your view model class file.
step 2: Define your Command,
public ICommand DoubleClickCommand
{
//Do your code
}
step 2: add the above said .dll into your corresponding solution's xaml file.
xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
step 3: Inside the Datagrid tag, use the below code to implement InvokeCommandAction Class
That's it. Hope it helps you:)