We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

ComboBox buttons

The cells that use CellType "ComboBox" do not display their contents in the area where the ComboBox button is displayed. If I set ShowButtons to GridShowButtons.Hide or GridShowButtons.ShowCurrentCell the buttons are not displayed, but still the text in the cell is clipped. Is there a way to get the text displayed? (I thought of things like switching the CellType between "TextBox" and "ComboBox" during (de)activation of a cell, but I am not shure about side-effects and hope there is an easier way). Thanks, Michael

1 Reply

CB Clay Burch Syncfusion Team August 14, 2002 02:07 PM UTC

Right now, one way you can do this is to derive a cell control based on GridComboBoxCellModel/Renderer, override the renderer OnDraw method, and adjust the rectangle if the cell is not current. Attached is a sample that shows how to do this. Though you have to add two classes, there is not much code that needs to be written. This sample more or less follows the steps outlined in the the Deriving Cell Controls tutorial in the User's Guide, though the coding is simpler than the LinkLabel code used in the tutorial.

Loader.
Live Chat Icon For mobile
Up arrow icon