Using 3.5 controls - Have Telerik project set to use the 3.5 binary inside my solution structure.
I have a web page with a gridview control with paging enabled. The data is coming from a sql datasource (I also tried changing it to use a List<> with the OnNeedDataSource event.
I can view the grid fine and page back and forth between the numeric pages however when I change the PageSize drop down I get this error message.
Exception Details: System.InvalidCastException: Unable to cast object of type 'ASP.masterpage_master' to type 'Telerik.Web.UI.GridTableView'.
Source Error:
Stack Trace:
I put the Telerik.Web.UI.DLL into reflector and inspected the raisepostbackevent method for the radgrid I'm only seeing 2 places where it directly casts it to a GridTableView
Is there any chance that eventArgument.Split is returning something like "this" that it would pick up the masterpage reference somehow?
Or does anyone have any idea what could be causing this error?
I have a web page with a gridview control with paging enabled. The data is coming from a sql datasource (I also tried changing it to use a List<> with the OnNeedDataSource event.
I can view the grid fine and page back and forth between the numeric pages however when I change the PageSize drop down I get this error message.
Unable to cast object of type 'ASP.masterpage_master' to type 'Telerik.Web.UI.GridTableView'.
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.InvalidCastException: Unable to cast object of type 'ASP.masterpage_master' to type 'Telerik.Web.UI.GridTableView'.
Source Error:
An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of
the exception can be identified using the exception stack trace below.
|
Stack Trace:
[InvalidCastException: Unable to cast object of type 'ASP.masterpage_master' to type 'Telerik.Web.UI.GridTableView'.] Telerik.Web.UI.RadGrid.RaisePostBackEvent(String eventArgument) +1719 System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +175 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565 |
I put the Telerik.Web.UI.DLL into reflector and inspected the raisepostbackevent method for the radgrid I'm only seeing 2 places where it directly casts it to a GridTableView
if (eventArgument.IndexOf("FireCommand") != -1) |
{ |
GridGroupByExpression expression2; |
GridGroupByExpression expression3; |
string id = eventArgument.Split(new char[] { ';' })[0].Split(new char[] { ':' })[1]; |
GridTableView tableView = (GridTableView) this.Page.FindControl(id); |
... |
if (eventArgument.IndexOf("ReorderColumns") != -1) |
{ |
GridTableView view = (GridTableView) this.Page.FindControl(eventArgument.Split(new char[] { ',' })[1]); |
Is there any chance that eventArgument.Split is returning something like "this" that it would pick up the masterpage reference somehow?
Or does anyone have any idea what could be causing this error?