GridGroupingControl - Remove dotted border in GroupDropArea.DragColumnHeaderText

Dear Syncfusion Support,

We are using V 4.2.0.37.

we are able to change gridGroupingControl1.GridGroupDropArea.DragColumnHeaderText. But we also want to remove the dotted border also..

We tried handling GridGroupDropArea_DrawCell and GridGroupDropArea_DrawCellDisplayText events too.

Can you plz let us know how to achive this?

Rgds
Rajani Kanth

2 Replies

AD Administrator Syncfusion Team September 28, 2006 05:14 AM UTC

Hi Rajani,

You can use the GroupDropArea.PrepareViewStyleInfo event to change the appearance of the groupdrop area text in a grid. Below is a code snippet.

private void GroupDropArea_PrepareViewStyleInfo(object sender, GridPrepareViewStyleInfoEventArgs e)
{
GridGroupDropArea area = sender as GridGroupDropArea;
GridGroupDropAreaModel model = area.Model as GridGroupDropAreaModel;
GridTable table = model.Table;
if (table.TableDescriptor.GroupedColumns.Count == 0 && e.RowIndex == 2 && e.ColIndex == 4)
{
e.Style.BackColor = Color.Blue;
e.Style.Borders.All = new GridBorder(GridBorderStyle.Solid);
}
}

Thanks,
Haneef


BR Badri Rajani Kanth September 28, 2006 01:08 PM UTC

Haneef,

In the condition if (table.TableDescriptor.GroupedColumns.Count == 0 && e.RowIndex == 2 && e.ColIndex == 4),

are values 2 and 4 always fixed? Can we take them as constants? Cause my grids have different settings in different screens. So, would like to if I can replace this condition with any thing like TableCellIdentity.TableCellType == "some thing"..

Rgds
Rajani Kanth

Loader.
Up arrow icon