Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1886
XamDatagrid ComboBoxItemsProvider - Selections blank out when leaving cell.
posted

Has anyone ever encountered a situation similar to the following.

I have a Class MyData that contains  BindingList<referenceData> and BindingList<PrimaryData>

A datagrid that is bound to BindingList<PrimaryData> is presenting a column as a combobox - the ComboBoxItemsProvider.Itemssource is bound to a BindingList<referenceData>. 

When the form is constructed, an instance of MyData is created, both binding lists are created (count = 0) and the bindings are established (Datasource and itemSource).

Then upon a user action, the MyData.ReferenceData binding list is populated.  The userInterface properly reflects this and the dropdown (in the addnewrow) now contains the appropriate reference data.

BUT, If I select a value from the drop down, and tab to the next field in the datagrid, the cell no longer contains a value (its blank).

Furthermore, if a user action then causes the Mydata.PrimaryData list to be populated, the Datagrid now reflects the records that were added to the class.  but the same behavior still exists when a combo item is selected and tabbed off of.

to add to the confusion - If the MyData instance is populated with both ReferenceData and PrimaryData - then the bindings occur (datasource and itemsource)  Everything works correctly!

This senario is encountered in 2 places deep within our complete application.  I have been unable to reproduce it in a simple application - so i havent included one (I will keep trying).  

Could anyone provide some guidance or thoughts as to what may be happening here.

Thanks in Advance