Bug #34516 Clicking "NN" or "AI" checkboxes without highlighting a field causes error
Submitted: 13 Feb 2008 9:16 Modified: 13 Feb 2008 18:29
Reporter: Gavin Greenwalt Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Workbench Severity:S2 (Serious)
Version:5.0.13 OS:Microsoft Windows (XP SP2)
Assigned to: CPU Architecture:Any
Tags: workbench
Triage: D3 (Medium)

[13 Feb 2008 9:16] Gavin Greenwalt
Description:
Clicking either the NN or AI checkboxes in the columns tab without first highlighting a field results in a JIT compile error.

Relevant parts of error message:
"************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
   at MySQL.GUI.Workbench.Plugins.DbMysqlTableColumnsListModel.ValuePushed(Object sender, NodeControlValueEventArgs e)
   at Aga.Controls.Tree.NodeControls.BindableControl.OnValuePushed(NodeControlValueEventArgs args)
   at Aga.Controls.Tree.NodeControls.BindableControl.SetValue(TreeNodeAdv node, Object value)
   at Aga.Controls.Tree.NodeControls.NodeCheckBox.SetCheckState(TreeNodeAdv node, CheckState value)
   at Aga.Controls.Tree.NodeControls.NodeCheckBox.MouseDown(TreeNodeAdvMouseEventArgs args)
   at Aga.Controls.Tree.TreeViewAdv.OnMouseDown(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseDown(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
"

How to repeat:
In a new project:

Add a table.
Click on the Columns tab.
Click somewhere in the columns box not on a column entry to deselect all column fields.  (aka white space)
Click NN or AI checkboxes.

Usually just kicks up an error message but occasionally will result in a freeze and inability to save.
[13 Feb 2008 9:24] Miguel Solorzano
Thank you for the bug report.
[13 Feb 2008 18:29] Johannes Taxacher
duplicate of http://bugs.mysql.com/bug.php?id=34418