[Mono-bugs] [Bug 521951] Assigning DataTables to ComboBox DataSources causes cast execption

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Sun Aug 16 16:24:53 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=521951

User timotheus.pokorra at gmail.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=521951#c2


Timotheus Pokorra <timotheus.pokorra at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         OS/Version|Mac OS X 10.5               |All




--- Comment #2 from Timotheus Pokorra <timotheus.pokorra at gmail.com>  2009-08-16 14:24:49 MDT ---
I have now thoroughly investigated the problem, and have come to the conclusion
that it is the same problem.

In the example with the comboboxes, the Stacktrace you get in the exception
"Cannot cast from source type to destination type." is:

  at System.Data.DataViewManager.CollectionToListChangeEventArgs
(System.ComponentModel.CollectionChangeEventArgs e) [0x00000] 
  at System.Data.DataViewManager.TableCollectionChanged (System.Object sender,
System.ComponentModel.CollectionChangeEventArgs e) [0x00000] 
  at System.Data.DataTableCollection.OnCollectionChanged
(System.ComponentModel.CollectionChangeEventArgs ccevent) [0x00000] 
  at System.Data.DataTableCollection.Add (System.Data.DataTable table)
[0x00000] 
  at System.Data.DataTableCollection.Add (System.String name) [0x00000] 
  at testbugmonotables.MainForm..ctor () [0x00000] 

I have had a look into that file, and the cause of the problem is in revision
122315 by ivanz:
http://anonsvn.mono-project.com/viewvc/trunk/mcs/class/System.Data/System.Data/DataViewManager.cs?r1=122315&r2=111855

e.Element is in our problem situation of type System.Data.DataTable, and the
cast to DataRelation fails.

It would be good to get that fixed. 

Thanks,
  Timo

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list