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.
Unfortunately, activation email could not send to your email. Please try again.

Increase divider width between cols in GridDataBoundGrid?

Thread ID:

Created:

Updated:

Platform:

Replies:

49672 Sep 22,2006 03:29 PM Sep 25,2006 12:48 PM Windows Forms 3
loading
Tags: GridControl
Ken Overton
Asked On September 22, 2006 03:29 PM

I want the nearest equiv of DataColumn.DividerWidth so that I can visually partition a single grid via thick dividers.

Ken Overton
Replied On September 22, 2006 03:31 PM

Sorry, I meant I want the equivalent of DataGridViewColumn.DividerWidth.

Administrator [Syncfusion]
Replied On September 25, 2006 08:22 AM

Hi Kov,

Please try the code below in the PrepareViewStyleInfo event, to see if this gives you what you needed.

// Form_Load
this.gridDataBoundGrid1.Model.Options.DefaultGridBorderStyle = GridBorderStyle.Solid;
this.gridDataBoundGrid1.Model.Properties.GridLineColor = Color.Silver;
this.gridDataBoundGrid1.PrepareViewStyleInfo += new GridPrepareViewStyleInfoEventHandler(gridDataBoundGrid1_PrepareViewStyleInfo);

// PrepareViewStyleInfo event
private void gridDataBoundGrid1_PrepareViewStyleInfo(object sender, GridPrepareViewStyleInfoEventArgs e)
{
if( e.ColIndex > 0)
{
e.Style.Borders.Right = new GridBorder(GridBorderStyle.Solid, Color.Silver, GridBorderWeight.ExtraThick);
}
}

Ken Overton
Replied On September 25, 2006 12:48 PM

Great, thanks very much.

A minor nit: it''s too bad that we have to prescribe the gridlinecolor rather than letting it use the default.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;