Hi together,
I have placed an
UltraControlContainerEditor hUltraControlContainerEditor = new UltraControlContainerEditor();hUltraControlContainerEditor.EditingControl = new EditorButtonInGridUserControl();
in a UltraWinGrid cell a UserControl which itself contains an UltraTextEditor. This editor has a right DropDownEditorButton which contains another UserControl. This sub UserControl contains also an UltraWinGrid.
The cosmetical issue is that the cell "StartChan" does show the UltraTextEditor with DropDownEditorButton only when I click with the mouse in this cell. If I don't that the original "StartChan" cell (as we can see in the first row) will be shown.
How can I permanently show the UltraTextEditor in every row with his right DropDownEditorButton in the parent grid?
Thank you very much for any idea!
The solution was setting RenderingControl in the UltraControlContainerEditor to an other instance ot the UserControl for rendering the cell, if it is not in edit mode.Setting UltraControlContainerEditor.EditingControl and UltraControlContainerEditor.RenderingControl to the same instance does fire an System.ArgumentException.Message="The EditingControl and the RenderingControl cannot be the same instance”The idea for doing this was found in those two posts:http://community.infragistics.com/forums/p/37062/214493.aspx#214493http://blogs.infragistics.com/forums/p/38813/221960.aspxThank you all for your helping and the valuable suggestions.Best regards and happy coding!
I'm having a hard time following what you are trying to do here. If you want to display a UserControl as a DropDown in a cell of the grid, then you do not need to use UltraControlContainerEditor. UltraControlContainerEditor is only for when you want a custom control to appear in the cell itself - NOT as a dropdown.
It sounds to me like your column editor should simply be an UltraTextEditor with a DropDownEditorButton in the ButtonsRight collection which has your UserControl set as it's Control property.
In that case, Amiram's solution will work.
Normal 0 21 false false false MicrosoftInternetExplorer4
Thank you very much for your quick reply, but this is not the right solution because I do not have a button in this original cell.
I have assigned a UserControl to this cell with the UltraControlContainerEditor.
In my opinion there are existing now two object’s the original cell "StartChan" and the assigned UserControl. The thing to do is to hide or delete the original cell and always show the UserControl which is in the UltraControlContainerEditor.
Best regards and thank you again!
Set the column button display style to Always
http://help.infragistics.com/Help/NetAdvantage/NET/2008.2/CLR2.0/html/Infragistics2.Win.UltraWinGrid.v8.2~Infragistics.Win.UltraWinGrid.UltraGridColumn~ButtonDisplayStyle.html