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

[Solved] Custom column editors being passed "Telerik.Web.UI.GridInsertionObject"

2 Answers 251 Views
Grid
This is a migrated thread and some comments may be shown as answers.
David Apelt
Top achievements
Rank 1
David Apelt asked on 07 Apr 2008, 05:16 AM
We are upgrading our internal control library to use the Prometheus Futures. With the RadGrid (Ver 2008.1.325.35) we have place a level of abstraction around it so that it will natively talk to our ORM framework.

We have found a problem when we click the 'Add new row' icon.  When the databinding occurs and calls our custom column editors that inherit from GridTextColumnEditor the value of the Text property is set to string "Telerik.Web.UI.GridInsertionObject" rather than the empty string.

This used to work with RadControl ASP.NET

I have attempted to simulate the problem using a statically loaded grid and a custom column editor but I could not reproduce the problem.  In order to properly reproduce the problem I may have to spend some time (ie days) carefully unpeeling our abstraction layer until I isloate the problem. 

Do you have any ideas about where the problem may lay?

Regards
Dave A


[FormatException: Input string was not in a correct format.]  
   System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +2755599  
   System.Number.ParseDouble(String value, NumberStyles options, NumberFormatInfo numfmt) +117  
   System.Double.Parse(String s, NumberStyles style, NumberFormatInfo info) +189  
   System.Double.Parse(String s) +20  
   Signmanager.Web.UI.WebControls.FloatingPointEditor.set_Text(String value) +153  
   Telerik.Web.UI.GridBoundColumn.OnDataBindColumn(Object sender, EventArgs e) +825  
   System.Web.UI.Control.OnDataBinding(EventArgs e) +99  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +206  
   System.Web.UI.Control.DataBind() +12  
   System.Web.UI.Control.DataBindChildren() +204  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +216  
   System.Web.UI.Control.DataBind() +12  
   System.Web.UI.Control.DataBindChildren() +204  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +216  
   System.Web.UI.Control.DataBind() +12  
   System.Web.UI.Control.DataBindChildren() +204  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +216  
   System.Web.UI.Control.DataBind() +12  
   System.Web.UI.Control.DataBindChildren() +204  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +216  
   System.Web.UI.Control.DataBind() +12  
   System.Web.UI.Control.DataBindChildren() +204  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +216  
   System.Web.UI.Control.DataBind() +12  
   System.Web.UI.Control.DataBindChildren() +204  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +216  
   System.Web.UI.Control.DataBind() +12  
   System.Web.UI.Control.DataBindChildren() +204  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +216  
   System.Web.UI.Control.DataBind() +12  
   System.Web.UI.Control.DataBindChildren() +204  
   System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) +216  
   System.Web.UI.Control.DataBind() +12  
   Telerik.Web.UI.GridEditFormItem.SetupItem(Boolean dataBind, Object dataItem, GridColumn[] columns, ControlCollection rows) +477  
   Telerik.Web.UI.GridTableView.CreateInsertItem(Boolean useDataSource, GridEnumerableBase resolvedDataSource, ControlCollection rows) +468  
   Telerik.Web.UI.GridTableView.CreateTopInsertItem(Boolean useDataSource, GridEnumerableBase resolvedDataSource, GridTHead tHead) +114  
   Telerik.Web.UI.GridTableView.CreateControlHierarchy(Boolean useDataSource) +1483  
   Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource) +638  
   System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data) +59  
   System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data) +111  
   System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +29  
   System.Web.UI.WebControls.DataBoundControl.PerformSelect() +149  
   Telerik.Web.UI.GridTableView.PerformSelect() +42  
   System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +70  
   Telerik.Web.UI.GridTableView.DataBind() +461  
   Telerik.Web.UI.GridTableView.Rebind() +130  
   Telerik.Web.UI.GridTableView.InsertItem(IDictionary newValues) +255  
   Telerik.Web.UI.GridTableView.InsertItem() +47  
   Telerik.Web.UI.GridCommandEventArgs.ExecuteCommand(Object source) +5023  
   Telerik.Web.UI.RadGrid.OnBubbleEvent(Object source, EventArgs e) +233  
   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35  
   Telerik.Web.UI.GridItem.OnBubbleEvent(Object source, EventArgs e) +95  
   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35  
   Telerik.Web.UI.GridItem.OnBubbleEvent(Object source, EventArgs e) +198  
   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35  
   System.Web.UI.WebControls.Button.OnCommand(CommandEventArgs e) +115  
   System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +163  
   System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7  
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11  
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33  
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1746  
 

2 Answers, 1 is accepted

Sort by
0
Rosen
Telerik team
answered on 09 Apr 2008, 12:17 PM
Hello David Apelt,

Unfortunately I'm not sure what may be the cause of this unwanted behavior with the given details. Therefore we will highly appreciate it if you can send us (attached to a formal ticket) a small working project in which this behavior can be reproduced. Doing so, we will be able to gather more details about your case and hopefully supply you with a suitable solution.

Regards,
Rosen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Neil
Top achievements
Rank 1
answered on 25 Apr 2008, 02:32 PM
David,
I'm using NHibernate, and I was having an identical problem. I was able to solve it by simply changing the DataSource of my grid.

When I was having the problem, I was doing something like:
IList queryqueryResults = query.List(); 
myGrid.DataSource = queryResults

To fix it, I changed the IList to a generic version:
IList<MyORMType> queryqueryResults = query.List<MyORMType>(); 
myGrid.DataSource = queryResults

Maybe using the generic list lets the RadGrid do some reflection to get extra info. Who knows, but it works for me.
Tags
Grid
Asked by
David Apelt
Top achievements
Rank 1
Answers by
Rosen
Telerik team
Neil
Top achievements
Rank 1
Share this question
or