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

How to hide or change the table name text

I noticed in the grouping drop area, table name is displaying before "Drag a column header here to group by that column". How can I not display it or change the table name to other text?

9 Replies

AD Administrator Syncfusion Team October 1, 2004 02:37 AM

The droparea is actually a little grid. And these text entries are being set in the model.OnQueryCellInfo method for that grid. So, for now, to change these values, you have to derive this model class and override its OnQueryCellInfo. (In the future, maybe we can do something to make this easier - allowing an event that you could handle to set them - but for now, you have to subclass the model.) Here is a little sample showing how you can do it. GGCHeaderText_8578.zip


AD Administrator Syncfusion Team October 1, 2004 05:47 AM

It turns out you can also do this by handling the GridGroupDropArea''s PrepareViewStyleInfo event. This would not require deriving the model. Here is a sample


AD Administrator Syncfusion Team October 1, 2004 10:45 AM

I used your sample code in GridGroupDropArea''s PrepareViewStyleInfo . Now my program works well. I prefer this way rather than the model way. Thank you for help. >It turns out you can also do this by handling the GridGroupDropArea''s PrepareViewStyleInfo event. This would not require deriving the model. >Here is a sample


PP Pravin Patel April 24, 2007 01:52 PM

How can I change Grid Group Drop Area bakground color.


HA haneefm Syncfusion Team April 24, 2007 02:29 PM

Hi,

The droparea is a little grid. So, you can handle its PrepareViewStyleInfo event, and explicitly set a backcolor there.

this.gridGroupingControl1.GridGroupDropArea.PrepareViewStyleInfo += new GridPrepareViewStyleInfoEventHandler(GridGroupDropArea_PrepareViewStyleInfo);

//the handler
private void GridGroupDropArea_PrepareViewStyleInfo(object sender, GridPrepareViewStyleInfoEventArgs e)
{
e.Style.BackColor = Color.Red;
}

Best regards,
Haneef


PP Pravin Patel April 24, 2007 02:45 PM

This does not work...
e.Style.BackColor is property to get BackColor does not allow to set the color.


HA haneefm Syncfusion Team April 24, 2007 02:53 PM

Hi,

Try setting these two properties.

this.gridGroupingControl1.GridGroupDropArea.Dock = DockStyle.Fill;
this.gridGroupingControl1.GridGroupDropArea.Model.Properties.BackgroundColor = Color.Red;

Here is a sample with the alpha blend selection set ok as well as coloring the group drop area.
GGCGroupDropAreaSample

Best regards,
Haneef


PP Pravin Patel April 24, 2007 03:11 PM

I can see in your sample it's red.
Now I have red background, but still the area where It says "My Table Drag a column header..." still has DarkControl background.


PP Pravin Patel April 24, 2007 03:23 PM

I got it. Thanks

Loader.
Live Chat Icon For mobile
Up arrow icon