Hi,
I'm working on an application in WinForms which uses a RadGridView to display information.
I have run "out of space" and want to display further information as tooltip.
When I databind the grid, I place this information in a column with Visible=false.
I have tried two ways withoug success.
First I tried he CellFormatting event as described in the Help Section on www.telerik.com.
I only want to display the tooltip, if there is information to show (FieldB is in the hidden column), but I get values everywhere, and the values are often wrong.
Then I tried to do it manually by using the DataBindingComplete and the CurrentCell property also described in the Help Section on www.telerik.com.
My problem is that CurentCell is always null.
I hope you can help me how to do this.
Best regards
Henning
I'm working on an application in WinForms which uses a RadGridView to display information.
I have run "out of space" and want to display further information as tooltip.
When I databind the grid, I place this information in a column with Visible=false.
I have tried two ways withoug success.
First I tried he CellFormatting event as described in the Help Section on www.telerik.com.
private void gwOffer_CellFormatting(object sender, CellFormattingEventArgs e){ if (gwOffer.Rows[e.CellElement.RowIndex].Cells["FieldA"].Value != null) { if (gwOffer.Rows[e.CellElement.RowIndex].Cells["FieldB"].Value != null) { e.CellElement.ToolTipText = "Sagsstatus: " + gwOffer.Rows[e.CellElement.RowIndex].Cells["FieldB"].Value; } }}Then I tried to do it manually by using the DataBindingComplete and the CurrentCell property also described in the Help Section on www.telerik.com.
private void gwOffer_DataBindingComplete(object sender, GridViewBindingCompleteEventArgs e){ for (int i = 0; i < gwOffer.Rows.Count; i++) { if (gwOffer.Rows[i].Cells["FieldA"].Value != null) { if (gwOffer.Rows[i].Cells["FieldB"].Value != null) { gwOffer.CurrentRow = gwOffer.Rows[i]; gwOffer.CurrentColumn = gwOffer.Columns["FieldA"]; GridDataCellElement cell = gwOffer.CurrentCell; if(cell!=null) cell.ToolTipText = "Sagsstatus: " + gwOffer.Rows[i].Cells["FieldB"].Value; } } }}I hope you can help me how to do this.
Best regards
Henning