I am creating a custom multi-select & multi-column combo editor and I want to use a usercontrol instead of the default popup control of ultracomboeditor.
I am using Infragistics v11.2 CLR4.
Hello Priyam,
Thank you for posting in our forum.
You may show your user control in BeforeDropDown event of UltraComboEditor and then cancel the event. This will suppress the showing of the default dropdown. You can use code like this:
private void UltraComboEditor_BeforeDropDown(object sender, CancelEventArgs e)
{
// Add your custom logic here to show your user control
e.Cancel = true;
}
Please let me know if you have any additional questions.
Thank you for using Infragistics Controls.
Hi Milko,
Could you please provide a small example? Do I have to use a popup container? I have a user control which needs to be displayed and since I am replacing existing UltraComboEditors in my application with this new User Control, it would be more helpful if I don't have to change the existing implementations of the UltraComboEditors.
No, there's no way to simply replace the popup control for every combo in the app.
The only way to do this is the approach I linked above. Use an EditorButton in the ButtonsRight or ButtonsLeft collection. And then you have to handle the keyboard and mouse interaction for your popup control.
Yes I have seen this post.
But as I said earlier I am looking for a way to use the ultracomboeditors and just override the popup.
I do not want to replace all the ultracomboeditors that are used across many applications with ultraTextEditors and then use the custom popup as this would mean that all existing code / logic around those ultracomboeditors also would have to be modified which would require huge amount of testing.
There is a quick example of this technique here.