I have a Winform with an UltraToolbarsManager (toolbarsManager) control, if I change the UltraComboEditor customerCombo control value (selecting a value from the dropdownlist) and then select an option from the toolbar, the customerCombo_SelectionChanged event is not fired until I close the window. How to fire the event BEFORE toolbarsManager_ToolClick event? Thanks.
By the way, I'm using NetAdvantange for .NET version 12.2.20122.2006
UltraToolbarsManager, like any toolbar, doesn't take focus. It can't because if it did, you would not be able to implement any buttons that rely on the current active control on the form. For example: cut, copy, and paste would be impossible, since you wouldn't know which control to apply them to.
If you select an item from the list, I would think that SelectedChanged would fire immediately, though. I don't see any reason why that should not fire until the control loses focus. But... if that's happening for whatever reason, you probably just have to call the Validate method on the form to validate any controls with pending changes.
Thank you Mike, after a better research I found that I was wrong, SelectedChanged event is really fired as you said, immediately after selecting an item from the list. The real problem is that it is fired twice, one after selecting the item and one more time after the Close() window event. I never change the customerCombo value or selected item during closing but I know SelectedChanged event is fired before the window is disposed. I have tried to reproduce this issue in a new simple test project but in this case it works fine. Then in this new panorama, what could be wrong? By now I will have to use a flag to control if the event should continue executing or not.
Hi,
You could use the following code in order to achieve that:
private void ultraGrid1_InitializeLayout(object sender, InitializeLayoutEventArgs e)
{
e.Layout.Override.AllowRowFiltering = Infragistics.Win.DefaultableBoolean.True;
ValueList valueList = e.Layout.FilterOperatorsValueList;
foreach (ValueListItem item in valueList.ValueListItems)
FilterComparisionOperator filterOperator = (FilterComparisionOperator)item.DataValue;
if (FilterComparisionOperator.Contains == filterOperator)
item.Appearance.Image = SystemIcons.Asterisk.ToBitmap();
}
Please feel free to let me know if a question about our tool set comes up on your mind.
I wanted to know if you were able to solve your issue based on these suggestions or you still need help. Please let me know.
Boris, we are in different threads, my post is not related to Ramish's post.
Hello oktober,
Can you please post a small sample project with the issue then?
I am checking about the progress of this issue. Please let me know If you need any further assistance on this.