Completed
Last Updated: 07 Jul 2025 07:29 by ADMIN
Release 2025.2.707
David
Created on: 26 Jun 2025 10:51
Category: PersistenceFramework
Type: Bug Report
0
PersistanceFramework: Missing types regarding GridViewColumns cause exceptions when saving

Missing types regarding GridViewColumns cause exceptions when saving: 

 

Workaround

Add the types manually:

radGridView.ItemsSource = sampleData;
manager.AllowGridViewControls();

manager.AllowedTypes.Add(typeof(GridViewToggleRowDetailsColumn));
manager.AllowedTypes.Add(typeof(GridViewDataColumn));
manager.AllowedTypes.Add(typeof(DependencyObject));
manager.AllowedTypes.Add(typeof(Size));
manager.AllowedTypes.Add(typeof(SizeConverter));

var gridViewColumnType = typeof(Telerik.Windows.Controls.GridViewColumn);
var assembly = gridViewColumnType.Assembly;

// Get the internal type by its full name
var internalType = assembly.GetType("Telerik.Windows.Controls.GridViewColumnCollectionInternal", throwOnError: false);

// Use the type as needed (for example, add to AllowedTypes if required)
if (internalType != null)
{
    manager.AllowedTypes.Add(internalType);
}

0 comments