Hi,
I am using an UltraWinGrid to display properties of SQL database tables in the switchboard screen of my app.
All of the databases involved, except 1, recieve the data in the same format. That last database has a join to a definitions table I am using. This makes their set of field names different. ... i think I just answered my own question as to how to workaround... but.
That doesn't let you guys off the hook :)
If I have opened the Field Chooser and then switch between those two databases then the whole app flushes with the dreaded key not found error.
I looked very hard but found no way to access and so catch anything to do with the FieldChooser from the model. The examples I found that gave me hope are for WPF...
I am going to force the two datasources to have the same field names and try to just adjust the visibles and 'hide from FieldChooser' settings on the fly ... that should do it...
Mind you if this blows up to when I hide the fields from the field chooser, too, I can name a certain Fortune 500 company that will be taking a closer look at certain Brand X control packages.... :)
Thanks in advance guys,
Mitch
I am waiting for our POC to update the download on our network. So I have not been able to validate the fix yet.
I spotted the issue while working on an analysis application that is IT/Dev side of the aisle and not customer facing (so I may have to wait a little while).
Again, I appreciate this and getting me the workaround as quick as you guys did.
I will respond as soon as I have the update.
Hello Mitch,
This has been addressed in service release versions WinForms_14.1.20141.2059, WinForms_13.2.20132.2075. At this time do you happen to have any additional questions?
I have opened a private case for you so that I can link it to an internal development issue. This way you will be notified automatically when the dev issue is updated. The case number is CAS-138547-L6Y2F2. You will see it located here: https://es.infragistics.com/my-account/support-activity
Let me know if you have any questions regarding this matter.
Interesting. It works when you set the DataSource property, but it doesn't work when you call SetDataBinding.
Yes, that worked, Mike.
I added the following to 'just before' every place the grid's datasource could change and the ColumnChooser disappears like a champ everytime.
I really just didn't know how to get access to the instance of the ColumnChooser (highlight below); threw in the databindings.clear, but it works without.
Here is the code translated to VB.Net, for those who need it.
Private Sub ultgrdDef_BeforeColumnChooserDisplayed(sender As Object, e As Infragistics.Win.UltraWinGrid.BeforeColumnChooserDisplayedEventArgs) Handles ultgrdDef.BeforeColumnChooserDisplayed Me.m_columnChooserDialog = e.Dialog AddHandler Me.m_columnChooserDialog.FormClosed, New FormClosedEventHandler(AddressOf columnChooserDialog_FormClosed)End Sub
Private Sub columnChooserDialog_FormClosed(sender As Object, e As System.Windows.Forms.FormClosedEventArgs) Handles m_columnChooserDialog.FormClosed RemoveHandler Me.m_columnChooserDialog.FormClosed, New FormClosedEventHandler(AddressOf columnChooserDialog_FormClosed) Me.m_columnChooserDialog = NothingEnd Sub
'This chunk preceeds any place the grid can have it's datasource changed
If Me.m_columnChooserDialog IsNot Nothing Then m_columnChooserDialog.DataBindings.Clear() Me.m_columnChooserDialog.DisposeOnClose = Infragistics.Win.DefaultableBoolean.[True] Me.m_columnChooserDialog.Close() End If
Thanks, I really wanted this to work.