Hello,
I followed setting up a RadGridView using a RadEntityFrameworkCoreDataSource using the MVVM approach outlined here.
This worked as expected for loading the data just fine. However, when I enabled the grid's CanUserInsertRow parameter, and try to add a row via the grid, I immediately get an exception from the AddingNewDataItem event stating that it cannot track the Entity of type <whatever> due to the primary key property being null. This would make sense to me if it were trying to commit the new row to the data source, but that would be after the user has a chance to enter the field information.
I understand there's an opportunity to set default values for these entities, however I wanted the user to input information themselves first, instead of setting up a valid row.
Previously, I have used DataTables/Views as a grid's item source with no problems, was able to capture exceptions thrown by the database in the UI itself and display them to the user.
Is this approach simply not suited for the Entity Framework data source? Or am I not familiar enough with this and MVVM, and should get myself caught up before continuing on?
Thanks for any help or suggestions,
Lee