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

GridControl setting boder style

ES 2.0.6.0 What am I doing wrong here? I just want to set the border style to solid and I''m trying this code: this.m_Grid[nRow, n].Borders.Bottom.Style = GridBorderStyle.Solid; Unfortunately it tells me that Syncfusion.Windows.Forms.Grid.GridBorder.Style is read-only. How can I programmatically set the border style?

3 Replies

AD Administrator Syncfusion Team July 29, 2004 10:32 AM

Try this code. this.m_Grid[nRow, n].Borders.Bottom = new GridBorder(GridBorderStyle.Solid);


SG Sean Greer July 29, 2004 10:50 AM

Yep, I figured that one out. I was looking at the CellStyles sample and noticed that the property grid is able to change a cell''s border style. How is that? Is there a custom propertydescriptor in the mix?


AD Administrator Syncfusion Team July 29, 2004 11:05 AM

Yes. Grid\Src\Base\Styles\GridBorderStyleEditor.cs(21): internal class GridBorderStyleEditor : UITypeEditor

Loader.
Live Chat Icon For mobile
Up arrow icon