Quantcast
Viewing all articles
Browse latest Browse all 18858

Datagrid column Sorting generating error

I have a datagrid column whose column values are databinded. I have used DataGridTemplateColumn and i need to use the sorting in this column.

<my:DataGridTemplateColumn SortMemberPath="FileName" Header="Name" IsReadOnly="True" MinWidth="150">

It works and sort the the data but when i edit the data after sorting, i need to re-generate the columns data.

FileListingGrid.ItemsSource = listFiles1;

But this generates "'Sorting' is not allowed during an AddNew or EditItem transaction."

It works file when column data is not sorted but whenever i sort the data and have to re-generate the column data, it throws the following error.

 


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>