This is my first posting in this forum.
I am currently having an issue where by a DataTable returned from the Database Query 'may' contains exponents and when I attempted to Bind the table [Basic Binding]:
RadGrid.DataSource = DataTable;
RadGrid.DataBind(); // Error Generated at this code location
Please refer to attached for a simple snapshot as to data for binding that is generating the error.
I have tried to identify the exact RadGrid Events where this exception is generated but I was unable to determine the event.
Is there a way for the Radgrid to handle these values (via settings) or do I have to handle it manually in the correct Radgrid event?
Thanks.
The Exception is:
System.Web.HttpUnhandledException: Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.FormatException: Input string was not in a correct format.
at System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal)
at System.Number.ParseDecimal(String value, NumberStyles options, NumberFormatInfo numfmt)
at Telerik.Web.UI.GridDataSetHelper.Add(Object a, Object b)
at Telerik.Web.UI.GridDataSetHelper.CalculateAggregates(DataRow SourceRow, DataRow DestRow, Int32 rowCountInGroup, GridTableView view)
at Telerik.Web.UI.GridDataSetHelper.InsertGroupByInto(GridTableView gridTableView, DataTable DestTable, DataTable SourceTable, String RowFilter, Int32 FirstIndexInPage, Int32 LastIndexInPage, Boolean ApplyPaging, Boolean IsCustomPaging)
at Telerik.Web.UI.GridDataSetHelper.CalcGroupByTables(GridTableView gridTableView, DataTable SourceTable, String RowFilter, Int32 FirstIndex, Int32 LastIndex, Boolean applyPaging, Boolean isCustomPaging)
at Telerik.Web.UI.GridEnumerableFromDataView.PerformTransformation()
at Telerik.Web.UI.GridEnumerableFromDataView.TransformEnumerable()
at Telerik.Web.UI.GridTableView.GetEnumerator(Boolean useDataSource, GridEnumerableBase resolvedDataSource, ArrayList dataKeysArray)
at Telerik.Web.UI.GridTableView.CreateControlHierarchy(Boolean useDataSource)
at Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource)
at System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data)
at System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data)
at System.Web.UI.WebControls.DataBoundControl.PerformSelect()
at Telerik.Web.UI.GridTableView.PerformSelect()
at Telerik.Web.UI.GridTableView.DataBind()
at Telerik.Web.UI.RadGrid.DataBind()
at Pages_Forecasts_StockForecastDrillDown.LoadSecurityFactors(String tDate, DataTable dt) in c:\Perforce\Acadian\Portal\MAIN\Research\web\Pages\Forecasts\StockForecastDrillDown.aspx.cs:line 986
at Pages_Forecasts_StockForecastDrillDown.ucSecuritySelect_SelectedIndexChanged(Object sender, SecuritySearchEventArgs e) in c:\Perforce\Acadian\Portal\MAIN\Research\web\Pages\Forecasts\StockForecastDrillDown.aspx.cs:line 842
at Controls_SecurityDropDownList.OnSecurityChanged(SecuritySearchEventArgs e) in c:\Perforce\Acadian\Portal\MAIN\Research\web\Controls\SecurityDropDownList.ascx.cs:line 40
at Controls_SecurityDropDownList.cboSecurity_SelectedIndexChanged(Object o, RadComboBoxSelectedIndexChangedEventArgs e) in c:\Perforce\Acadian\Portal\MAIN\Research\web\Controls\SecurityDropDownList.ascx.cs:line 224
at Telerik.Web.UI.RadComboBox.OnSelectedIndexChanged()
at System.Web.UI.Page.RaiseChangedEvents()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
--- End of inner exception stack trace ---
at System.Web.UI.Page.HandleError(Exception e)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.HttpContext.InvokeCancellableCallback(WaitCallback callback, Object state)
at System.Web.UI.Page.AsyncPageBeginProcessRequest(HttpContext context, AsyncCallback callback, Object extraData)
at ASP.pages_forecasts_stockforecastdrilldown_aspx.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object data) in c:\Windows\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\8609db0b\e58b7a69\App_Web_stockforecastdrilldown.aspx.4393a603.ujchnqwd.0.cs:line 0
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)