[Mono-bugs] [Bug 75100][Maj] New - Custom data formatting expressions don't appear to work in DataGrids

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Tue May 31 01:33:03 EDT 2005


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by camelweb at bigpond.com.

http://bugzilla.ximian.com/show_bug.cgi?id=75100

--- shadow/75100	2005-05-31 01:33:03.000000000 -0400
+++ shadow/75100.tmp.26659	2005-05-31 01:33:03.000000000 -0400
@@ -0,0 +1,88 @@
+Bug#: 75100
+Product: Mono: Class Libraries
+Version: 1.1
+OS: other
+OS Details: Fedora Core 3
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Major
+Component: Sys.Web
+AssignedTo: mono-bugs at ximian.com                            
+ReportedBy: camelweb at bigpond.com               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Custom data formatting expressions don't appear to work in DataGrids
+
+Please fill in this template when reporting a bug, unless you know what you
+are doing.
+Description of Problem:
+Custom data formatting expressions don't appear to work in DataGrids
+
+
+Steps to reproduce the problem:
+1. In Visual Studio Create an aspx page
+2. Add a bound DataGrid (tested with SqlClient)
+3. Add a column that's based on a Numeric field
+4. Set Data formatting expression to {0:#.##} - this causes the exception below
+5. Set Data formatting expression to {0:g} - code runs fine
+
+Actual Results:
+This is the resulting exception :
+System.FormatException: The specified format is invalid
+in <0x003cf> System.DecimalFormatter:NumberToString (System.String format,
+System.Globalization.NumberFormatInfo nfi, Decimal value)
+in <0x0006f> System.Decimal:ToString (System.String format, IFormatProvider
+provider)
+in <0x0024c> System.String:FormatHelper (System.Text.StringBuilder result,
+IFormatProvider provider, System.String format, System.Object[] args)
+in <0x0002b> System.String:Format (IFormatProvider provider, System.String
+format, System.Object[] args)
+in <0x00037> System.String:Format (System.String format, System.Object arg0)
+in <0x00039> System.Web.UI.WebControls.BoundColumn:FormatDataValue
+(System.Object dataValue)
+in <0x00134> System.Web.UI.WebControls.BoundColumn:OnDataBindColumn
+(System.Object sender, System.EventArgs e)
+in (wrapper delegate-invoke)
+System.MulticastDelegate:invoke_void_object_EventArgs (object,System.EventArgs)
+in <0x00056> System.Web.UI.Control:OnDataBinding (System.EventArgs e)
+in <0x00013> System.Web.UI.Control:DataBind ()
+in <0x0006c> System.Web.UI.Control:DataBindChildren ()
+in <0x00021> System.Web.UI.Control:DataBind ()
+in <0x000af> System.Web.UI.WebControls.DataGrid:CreateItem (Int32
+itemIndex, Int32 dsIndex, ListItemType type, Boolean bind, System.Object
+item, System.Web.UI.WebControls.DataGridColumn[] columns,
+System.Web.UI.WebControls.TableRowCollection rows,
+System.Web.UI.WebControls.PagedDataSource dataSrc)
+in <0x00768> System.Web.UI.WebControls.DataGrid:CreateControlHierarchy
+(Boolean useDataSource)
+in <0x0003f> System.Web.UI.WebControls.BaseDataList:OnDataBinding
+(System.EventArgs e)
+in <0x00013> System.Web.UI.WebControls.BaseDataList:DataBind ()
+in <0x0006c> System.Web.UI.Control:DataBindChildren ()
+in <0x00021> System.Web.UI.Control:DataBind ()
+in <0x0006c> System.Web.UI.Control:DataBindChildren ()
+in <0x00021> System.Web.UI.Control:DataBind ()
+in <0x000c0> Produse.test:Page_Load (System.Object sender, System.EventArgs e)
+in (wrapper delegate-invoke)
+System.MulticastDelegate:invoke_void_object_EventArgs (object,System.EventArgs)
+in <0x00056> System.Web.UI.Control:OnLoad (System.EventArgs e)
+in <0x00026> System.Web.UI.Control:LoadRecursive ()
+in <0x00149> System.Web.UI.Page:InternalProcessRequest ()
+in <0x000a9> System.Web.UI.Page:ProcessRequest (System.Web.HttpContext context)
+in <0x00233> System.Web.HttpApplication+ExecuteHandlerState:Execute ()
+in <0x0007c> System.Web.HttpApplication+StateMachine:ExecuteState
+(IStateHandler state, System.Boolean readysync)
+
+
+
+Expected Results:
+A formatted number inside a DataGrid
+
+How often does this happen? 
+Everytime
+
+Additional Information:
+Doesn't happen for an Integer based number


More information about the mono-bugs mailing list