I would like to create a tooltip within the grid cells that contains text provided from another bound column. For example, assume I have a grid that contains a list of CategoryNames and CategoryValues. I have another bound column that has a CategoryDescription that I would only like to show upon a mouse-over of the CategoryName cell. I have seen the use of the grid_HtmlDataCellPrepared event, but cannot determine how to use this to attach towards another bound-column value.
How to create an ASPxGridView cell tooltip with values from other datacolumn?
Answers
Hi Michael,
Please refer to the tooltip thread to learn how to implement cell tooltips. If you wish to set another field value to the "title" attribute value, you should use the following code:
C#protected void ASPxGridView1_HtmlDataCellPrepared(object sender, DevExpress.Web.ASPxGridView.ASPxGridViewTableDataCellEventArgs e) {
e.Cell.Attributes.Add("title", e.GetValue(SomeOtherFieldName).ToString());
}
Thanks,
Plato