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

Making the grid control''s Accept focus to false

Hi, i need to make the grid not to recieve focus, means even if 1.I click on any of its cells the cell should not get focus, 2.The focus should be retained with the the previous control where the focus was previously 3.Also the focus rectangle around the cell should not be visible. I tried creating a control, deriving it form the grid control and in the ctor making the SetStyle selectable to false. But still its accepting focus. Is this a bug??? Or is there any work around to achieve the same??? Thanks, Atanu

3 Replies

AD Administrator Syncfusion Team September 6, 2005 02:30 PM UTC

Hi Atanu, You could try this: this.gridControl1.Enabled=false; Regards, Jeba.


AP Atanu Podder September 8, 2005 06:58 AM UTC

>Hi Atanu, > >You could try this: >this.gridControl1.Enabled=false; > >Regards, >Jeba. Hi, Jeba, I can do that, but thats not what my intension is as making it enabled false would change the look and feel. I want to make the control not to recieve focus but look like an enabled control. Thanks, Atanu


AD Administrator Syncfusion Team September 8, 2005 07:25 AM UTC

Try setting these properties on the grid. this.gridControl1.TableStyle.Enabled = false; this.gridControl1.BaseStylesMap["Header"].StyleInfo.Enabled = false; this.gridControl1.AllowSelection = GridSelectionFlags.None;

Loader.
Live Chat Icon For mobile
Up arrow icon