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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

GCC set tooltip with cellvalue by a hidden column

Thread ID:





70502 Dec 13,2007 02:53 PM UTC Dec 14,2007 11:31 AM UTC WinForms 2
Tags: GridControl
Lorenzo Grassi
Asked On December 13, 2007 02:53 PM UTC

I have a GGC with couple of column, one visible and one hidden. In the hidden column I have a description, and I want to set the tooltip of the visible column with the description taken from the hidden column.

I can set the tooltip on the ActivateToolTip event, but how can I get the value of the adiacent hidden cell?

There is another way to obtain a similar effect?

Thank you

Administrator [Syncfusion]
Replied On December 14, 2007 10:35 AM UTC

The grid has support for cell tips through its GridTableZCellStyleInfo.CellTip property. You can provide these tips dynamically by handling the QueryCellStyleInfo event. Here is code that displays the value of a cell Col1 one when the user hovers over a cell in Col2.

//subscribe to the event
this.gridGroupingControl1.QueryCellStyleInfo += new GridTableCellStyleInfoEventHandler(gridGroupingControl1_QueryCellStyleInfo);

//the event handler
void gridGroupingControl1_QueryCellStyleInfo(object sender, GridTableCellStyleInfoEventArgs e)
if (e.TableCellIdentity.Column != null
&& e.TableCellIdentity.Column.Name == "Col2")
GridRecord rec = e.TableCellIdentity.DisplayElement.GetRecord() as GridRecord;
if (rec != null)
object val = rec.GetValue("Col1");
e.Style.CellTipText = val.ToString();

Lorenzo Grassi
Replied On December 14, 2007 11:31 AM UTC

Great, it's what I need, thank you



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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon 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.Close Icon