Hi, I am using XamDataGrid.
I am updating the ActiveDataItem from ViewModel class and the respective DataItem in the view is Hilighted properly. But the previously selected dataitem in the View is not cleared still it is showing as a highlighted one even though it is not an ActiveDataItem.
Previously selected item using mouse in the view is not cleared when i change ActiveDataItem from ViewModel class.
So, my view is showing two highlighted DataItems instead of single ActiveDataItem.
Below is the code I am using for XamDataGrid
<igDP:XamDataGrid DataSource="{Binding Path=Filters,ValidatesOnExceptions=True, NotifyOnValidationError=True}" AutoFit="True" UseLayoutRounding="True" Name="FiltersGrid" SortRecordsByDataType="True" GroupByAreaLocation="None"
ActiveDataItem="{Binding FilterDataItem,Mode=TwoWay}" >
In ViewModel:
FilterDataItem = FilterData;
Any help will be greatly appreciated.
Hello Manoj,
Thank you for your post. I have been looking into it and I was able to reproduce your behavior. I can say that this is expected because when you set a Record to become an ActiveDataItem it doesn’t get selected and the previously selected one remains highlighted. I created a sample project for you, where I used DataPresenterCommands to clear the selected records and to make the ActiveDataItem selected. You can choose either to use them both or just one of a them as per your requirements.
Hope this help you.