Hello!
I got a whard problem with UltraCombo.
When I leave the combo with a TAB I get an exception that forces application to exit even when I covered all methods with try and catch blocks. Exception message is: "Can't access SelectionStart unless editor is in edit mode".
Here parts of the stacktrace:
at Infragistics.Win.EmbeddableEditorBase.get_SelectionStart()
at Infragistics.Win.UltraWinGrid.UltraCombo.OnBeforeEditorExitEditMode(Object sender, BeforeExitEditModeEventArgs e)
at Infragistics.Win.EmbeddableEditorBase.OnBeforeExitEditMode(Boolean& cancel, Boolean forceExit, Boolean applyChanges)
at Infragistics.Win.EditorWithText.OnBeforeExitEditMode(Boolean& cancel, Boolean forceExit, Boolean applyChanges)
at Infragistics.Win.EditorWithCombo.OnBeforeExitEditMode(Boolean& cancel, Boolean forceExit, Boolean applyChanges)
at Infragistics.Win.EmbeddableEditorBase.ExitEditMode(Boolean forceExit, Boolean applyChanges)
at Infragistics.Win.UltraWinGrid.UltraCombo.OnEditorKeyDown(Object sender, KeyEventArgs args)
at Infragistics.Win.EmbeddableEditorBase.RaiseKeyDownEvent(KeyEventArgs e)
at Infragistics.Win.EmbeddableTextBox.OnKeyDown(KeyEventArgs e)
at Infragistics.Win.EmbeddableTextBoxWithUIPermissions.ProcessKeyMessage(Message& msg)
at System.Windows.Forms.Control.WmKeyChar(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.TextBoxBase.WndProc(Message& m)
at System.Windows.Forms.TextBox.WndProc(Message& m)
I try to prevent firing an event when TAB is pressed, but which event can be supressed or how can I send the combo into edit mode?
I'm using Infragfistics Win 6.1
Thanks for any advice.
Are you handling the BeforeEditorExitEditMode event on the control?
If so, then you might want to see if your code inside that event is attempting to access the SelectionStart property on the control.
If you are not handling that event, then this is probably a bug in the control. In that case, the best thing I can suggest is that you get the latest service release and see if the bug is fixed.
How to get the latest service release - Infragistics Community