Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1500
UltraComboEditor dropdown button width
posted

Hi folks,

How can I determine the width of the UltraComboEditors dropdown button?

In the case you need more context here it is:

Here is what I'm trying to do: put custom text box over a grid's cell. It works perfectly good for text-only cells (just by adding text box to UltraGrid.Controls and specifying its position/size), but doesn't work that well with dropdown cells. Because our text box is put over the cell and at the same time over the dropdown button, that is not what is needed. Out text box has to be shown only above the textual part of the cell, not being over the dropdown button.

To do this, the width of our text box should be adjusted accordingly by descreasing it by the dropdown button width. The problems is that I cannot find the way to find the dropdown button width. UltraComboEditor is used as the editor for the dropdown cells.

Thanks,
Vitaly

  • 469350
    Verified Answer
    Offline posted

    Hi Vitaly,

    How are you determining the position/size of the TextBox? My guess is that you are using UIElements. If that's true, then you probably just need to change which UIElement you are using. Instead of using the CellUIElement, you should probably be using the EmbeddableUIElementBase or the EditorWithTextUIElement in the cell.

    If you are using the latest version of NetAdvantage, then you could use the UltraControlContainerEditor to embed a control in a cell and it would be much easier.