以文本方式查看主题

-  Foxtable(狐表)  (http://www.foxtable.com/bbs/index.asp)
--  BUG收集  (http://www.foxtable.com/bbs/list.asp?boardid=12)
----  关于表达式列的一个BUG  (http://www.foxtable.com/bbs/dispbbs.asp?boardid=12&id=73544)

--  作者:Hyphen
--  发布时间:2015/8/21 9:54:00
--  关于表达式列的一个BUG

以下BUG的重现请务必不要在正式项目下尝试,否则你会很痛苦的

 

BUG的出现,重复操作了5次,都出现这种情况:

 

1.创建一个新表,创建2个数据列(暂且命名为A,B),默认都是字符型的,先不要录入任何数据

 

2.新建一个表达式列C,为双精度数字型,表达式为“A*B”

 

3.在A列输入一个数字,在B列输入一个数字,(都是在同一行操作)焦点离开后,出现以下提示

 
此主题相关图片如下:1.png
按此在新窗口浏览图片


4.好吧,既然说string之间不能相乘,那就改列类型,先把A列改为整数型,改完后又出现了上图的错误提示

 

5.关闭错误提示窗口,不出以外的话就会出现,以下错误提示:

 


此主题相关图片如下:2.png
按此在新窗口浏览图片

 

6.然后点击确定,神奇的一刻来了,如下:


 


此主题相关图片如下:3.png
按此在新窗口浏览图片

 

.NET抛出来的提示是:

System.NullReferenceException: 未将对象引用设置到对象的实例。
   在 Foxtable.O__oO0__.o    0 0(Object A_0, OwnerDrawCellEventArgs A_1, Boolean A_2, Boolean A_3)
   在 Foxtable.O__oO0__.o____o__(Object A_0, OwnerDrawCellEventArgs A_1)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.OnOwnerDrawCell(OwnerDrawCellEventArgs e)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.?(OwnerDrawCellEventArgs e)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.?(Graphics g, Int32 row, Int32 col, Style s, Rectangle rc, String str, Image img)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.DrawCell(Graphics g, Int32 row, Int32 col, Style s, Rectangle rc, String str, Image img, CheckEnum chk)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.DrawCell(PaintEventArgs e, Int32 row, Int32 col)
   在 C1.Win.C1FlexGrid.C1FlexGrid.DrawCell(PaintEventArgs e, Int32 row, Int32 col)
   在 C1.Win.C1FlexGrid.C1FlexGrid.DrawRow(PaintEventArgs e, Int32 row)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.?(PaintEventArgs e)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.OnPaint(PaintEventArgs e)
   在 System.Windows.Forms.Control.PaintWithErrorHandling(PaintEventArgs e, Int16 layer, Boolean disposeEventArgs)
   在 System.Windows.Forms.Control.WmPaint(Message& m)
   在 System.Windows.Forms.Control.WndProc(Message& m)
   在 C1.Win.C1FlexGrid.Util.BaseControls.ScrollableControl.WndProc(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   在 System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

 

 

 


--  作者:Hyphen
--  发布时间:2015/8/21 9:56:00
--  

以下错误有时会出现,有时不会出现

 

既然这个表是不能用的了,删除吧,然后到其它表继续玩,嗯嗯,来了

 


此主题相关图片如下:4.png
按此在新窗口浏览图片

 

这次抛出来的提示是

System.ObjectDisposedException: 无法访问已释放的对象。
对象名:“oo__O__O”。
   在 System.Windows.Forms.Control.CreateHandle()
   在 System.Windows.Forms.TextBoxBase.CreateHandle()
   在 C1.Win.C1Input.C1TextBox.CreateHandle()
   在 System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
   在 System.Windows.Forms.Control.CreateControl()
   在 System.Windows.Forms.Control.SetVisibleCore(Boolean value)
   在 System.Windows.Forms.Control.set_Visible(Boolean value)
   在 ??.?.??(Char key, Point ptMouse, Boolean dblClick)
   在 ??.?.StartEditing(Int32 row, Int32 col, Char key, Boolean force, Point ptMouse, Boolean dblClick)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.StartEditing(Int32 row, Int32 col, Char key, Boolean force)
   在 C1.Win.C1FlexGrid.C1FlexGrid.StartEditing(Int32 row, Int32 col, Char key, Boolean force)
   在 ??.?.StartEditing(Char key)
   在 ??.?.OnKeyPress(KeyPressEventArgs e)
   在 C1.Win.C1FlexGrid.C1FlexGridBase.OnKeyPress(KeyPressEventArgs e)
   在 System.Windows.Forms.Control.ProcessKeyEventArgs(Message& m)
   在 System.Windows.Forms.Control.ProcessKeyMessage(Message& m)
   在 System.Windows.Forms.Control.WmKeyChar(Message& m)
   在 System.Windows.Forms.Control.WndProc(Message& m)
   在 C1.Win.C1FlexGrid.Util.BaseControls.ScrollableControl.WndProc(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   在 System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
[此贴子已经被作者于2015/8/21 9:56:28编辑过]