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.

Setting Cell Tool Tip via e.Inner.Style.CellTipText

Thread ID:





20572 Oct 21,2004 03:25 AM Nov 30,2011 08:31 AM Windows Forms 6
Tags: Grouping
Jason Hales
Asked On October 21, 2004 03:25 AM

I''m currently using the PrepareViewStyleInfo to set the tooltip when a user hovers over a specic column in the grid. It all works fine but I was wondering on the most effective way to do this - PrepareViewStyleInfo seems to be fired an awful lot. The tooltip never changes at runtime - it''s just calculated based on the record ID which I store in a hashtable. Is it possible to "lock" the CellTipText for a cell and only get it if it''s null? Is there a "Handled" or some sort of storage mechanism. Any help would be appreciated - excellet product so far

Administrator [Syncfusion]
Replied On October 21, 2004 04:13 AM

If the tip is the same for all cells in the column, you can set this in the columns Appearance object once, say in formload, or from the designer. this.gridGroupingControl1.TableDescriptor.Columns["Col2"].Appearance.AnyRecordFieldCell.CellTipText = "the column tip"; But if the tip is to vary for cell to cell in the column, then you would have to do it in TableControlPrepareViewStyleInfo or in QueryCellStyleInfo.

Jason Hales
Replied On October 25, 2004 02:49 AM

Thanks for your help - Jason

James Blibo
Replied On March 8, 2007 05:48 PM

Can you bind the tooltip to the datasource in the same manner that you bind the ggc to a datasource?

Administrator [Syncfusion]
Replied On March 9, 2007 03:34 PM

Hi James,

One way you can handle this by using QueryCellInfo event of the Grid and set the e.Style.CellTipText to underlying datasource value. Please try attached sample and let me know if this helps.


Best Regards,

SF Lee
Replied On November 28, 2011 06:34 PM


It seems the above link doesn't work. In fact the entire subdomain (http://websamples.syncfusion.com/) no longer exists. Can you please give us the new link for the sample code?


Ragamathulla B [Syncfusion]
Replied On November 30, 2011 08:31 AM

Hi Sau Fan Lee,

Thanks for the update.

You can set the celltooltip text by using QueryCellInfo or PrepareViewStyleInfo event. The following code Explains the same.

//Way 1

void TableControl_PrepareViewStyleInfo(object sender, GridPrepareViewStyleInfoEventArgs e)
e.Style.CellTipText = e.Style.Text;

//Way 2

void gridGroupingControl1_QueryCellStyleInfo(object sender, GridTableCellStyleInfoEventArgs e)
e.Style.CellTipText = e.Style.Text;

Please refer to the following sample link Which illustrates the same.


Please let me know if you have any further concerns.

Ragamathullah B.


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.