This is a migrated thread and some comments may be shown as answers.

grid sorting/edit error when using partial class property

2 Answers 69 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
J asked on 23 Feb 2009, 11:55 PM
Sys.WebForms.PageRequestsManagerServerErrorException: Cannot find column ColumnName

I have two partial classes:

public partial class Person { public stirng FirstName {get;set;} } //this is generated by SubSonic 2.1
public partial class Person { public stirng LastName {get;set;} } //this is hand written

When i bind Person collection to telerik grid and click to sort on LastName, i get the above error. but it works fine with FirstName column.
My project was using .NET 2.0 (VS2005) and it seemed to be working fine. Since I upgraded to .NET 3.5 all sorts issues all came up. This is just one of the issues.

I also noticed paging isn't working correctly.

GridDropDownColumn also stopped working with Edit command. seems the drop down can not be bind because missing column name from the class.

Is this a known bug with Telerik controls?
do i need to upgrade telerik? I am using telerik.web.ui.dll 2008.1.415.20
with vs2008, .net 3.5, application project


2 Answers, 1 is accepted

Sort by
Top achievements
Rank 1
answered on 25 Feb 2009, 01:15 AM
Cannot find column COLUMNNAME.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.IndexOutOfRangeException: Cannot find column COLUMNNAME.

Stack Trace:

[IndexOutOfRangeException: Cannot find column ColumnName.]
   System.Data.DataTable.ParseSortString(String sortString) +4824350
   System.Data.DataView.CheckSort(String sort) +32
   System.Data.DataView.set_Sort(String value) +128
   Telerik.Web.UI.GridEnumerableFromDataView.PerformTransformation() +4980
   Telerik.Web.UI.GridEnumerableFromDataView.TransformEnumerable() +41
   Telerik.Web.UI.GridTableView.GetEnumerator(Boolean useDataSource, GridEnumerableBase resolvedDataSource, ArrayList dataKeysArray) +171
   Telerik.Web.UI.GridTableView.CreateControlHierarchy(Boolean useDataSource) +356
   Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource) +588
   System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data) +57
   System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data) +114
   System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +31
   System.Web.UI.WebControls.DataBoundControl.PerformSelect() +142


when i try to sort on column it throws this error. however it displays no problem!!!
same thing happens to row edit, but works ok for add new

any ideas?
Telerik team
answered on 26 Feb 2009, 03:57 PM
Hello J,

It seems that you are using rather an old version of RadControls for ASP.NET AJAX (Q1 2008). Does migrating to the latest release 2008.3.1314 (Q3 2008 SP2) following the steps from this KB article addresses the issues you are facing? You can use the following online demos of the product for further reference:

Best regards,
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Asked by
Top achievements
Rank 1
Answers by
Top achievements
Rank 1
Telerik team
Share this question