Hi,
The listview has that weird behavior when setup with checkbox.
Let's create a list with checkbox and then group them by some field.
Then when I assign datasource with a new source or assign to null it will throw an exception
This property is related to its paint event and then the control crashes.
Another example. When I change .showcheckbox from true to False. then it will also lead to this exception.
Please check!
My wish: this property .checkitems returns null when the source is empty or when showcheckbox=false. and the checkbox no longer draws when changing .showcheckbox=false.
This would save me from having to recreate another class or set the datasource from scratch.
Thanks you!
Object reference not set to an instance of an object.
************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at Syncfusion.WinForms.ListView.SfListView.get_CheckedItems()
at Syncfusion.WinForms.ListView.SfListView.UnWiredEvents()
at Syncfusion.WinForms.ListView.SfListView.RefreshViewAndContainer(Object oldValue, Object newValue)
at Syncfusion.WinForms.ListView.ListViewPainter.OnPaint(PaintEventArgs e, Size clientSize)
at Syncfusion.WinForms.ListView.SfListView.OnPaint(PaintEventArgs e)
at System.Windows.Forms.Control.PaintWithErrorHandling(PaintEventArgs e, Int16 layer)
at System.Windows.Forms.Control.WmPaint(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at Syncfusion.WinForms.Controls.SfScrollControl.WndProc(Message& msg)
at Syncfusion.WinForms.ListView.SfListView.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
Attachment: Desktop_3a1df25.rar