StrataFrame Forum

Using ComboBox in Infragistics Ultragrid

http://forum.strataframe.net/Topic15576.aspx

By Aaron Young - 4/12/2008

Hi,

I would like to add a dropdown list to a column in an Ultragrid. I tried to use a SF ComboBox control as the EditorControl for the column. However, the following error is thrown when the application runs:-

"EditorControl property can only be set to a control that implements IProvidesEmbeddableEditor interface."

As the ComboBox doesn't implement this interface, how do you add dropdown lists to a column in an Ultragrid? Which control do you use?

Thanks,

Aaron

By Trent L. Taylor - 4/12/2008

As the ComboBox doesn't implement this interface, how do you add dropdown lists to a column in an Ultragrid? Which control do you use?

You would have to use an Infragistics combo, not a standard SF combo.  You should be able to use the Infragistics Wrapper combo as this inherits from the UltraCombo which should have than implementation.  If not, then it would be a matter of creating a custom class and just implementing that interface:

Public Class MyEmbeddableCombo
    Inherits MicroFour.StrataFrame.UI.WIndows.Forms.ComboBox
    Implements IProvidesEmbeddableEditor

End Class

In any case, you should be able to get it accomplished without too much effort.

By Aaron Young - 4/12/2008

I tried subclassing the combobox and implementing the interface but there are problems with that as the control is expected to expose several features, e.g. Editor, etc.

I will use the Infragistics combo instead. It probaby suits us as we already have a subclassed grid that will automatically create the dropdowns based on tag values. i doubt it will take much to convert this to create and populate a BO instead.

Thanks.

By Trent L. Taylor - 4/12/2008

Sounds good Smile