Question

public ICommand SelectionChanged
{
    get
    {
        return new RelayCommand(param => this.ExecuteSelectionChanged(param));
    }
}

private object ExecuteSelectionChanged(object param)
{
    var e = param as SelectionChangedEventArgs;
    var addedItem = e.AddedItems[0];
}

I want to do:

SelectionChanged.Execute(new SelectionChangedEventArgs( null,null, addedList)); 

But it is saying value cannot be null of event id. Any work around?

Was it helpful?

Solution

   SelectionChanged.Execute(new SelectionChangedEventArgs(ComboBox.SelectionChangedEvent, removeList,addList));
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top