The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
Is it possible to prevent a caret from appearing in a grid combo box cell without making the cell readonly/disabled.
I would like to have a combo box cell (with autocomplete/exclusive style) which can change values and autocompletes as you type the entry but doesn''t show the caret.
Thanks,
Sue
ADAdministrator Syncfusion Team August 8, 2005 08:27 AM UTC
You can try this property to see if that gives you what you want.
this.gridControl1.ActivateCurrentCellBehavior = GridCellActivateAction.None; //or DblClickOnCell
SHSue HarrisAugust 8, 2005 10:18 PM UTC
Hi Clay,
I''d already set that property. What I''m trying to do is to stop the caret appearing altogether, not just when the cell activates.
Thanks,
Sue
ADAdministrator Syncfusion Team August 9, 2005 01:11 AM UTC
I do not know a simple way to do this. I think you would have to derive GridComboBoxCellRenderer/Model and override OnKeyPress in the renderer class. It is this method that handles the autocomplete work and sets the value of the cell. The added complexity is that you will have to track the position in the string at which the next keystroke will be placed in the string. In teh standard cell, this is not a problem because the portion of teh text after teh current key is always selected, so teh nect key stroke natually replaces teh selection in teh actively editing cell. In your case, there are no selsections and not actively editing cell. This also means your user gets no visible feedback of wheich key he is about to press since there is no cursor or selected text.
Here is a rough try at this. http://www.syncfusion.com/Support/user/uploads/ComboBox_9f8c9974.zip