Setting A Tooltip For A Specific Cell Using Conditional Formatting

1 reply. Last post: March 7, 2011 3:48 AM by Yudi
Tags :
  • (None)
  • New Discussion
  • New Question
  • New Product Feedback

Hello InterSoft,

I would like to set a formatted tooltip that looks like a table using a webcallout object. My grid layout populated dinamically from xml file. I have attached a sample from Niven Prasetya which show how to do it if columns are created in aspx file. How to reproduce it using C# code. Please provide a sample.

I try to do this but it doesn't work:

foreach (WebGridColumn column in grid.RootTable.Columns)

{

if (column.Name == "TICKER")

column.ColumnType = ColumnType.Template;

}



protected void Grid_InitRow(object sender, ISNet.WebUI.WebGrid.RowEventArgs e)

{

if (e.Row.Cells.GetNamedItem("TICKER") != null)

{

WebGridCellTemplateContainer cell = e.Row.Cells.GetNamedItem("TICKER").GetTemplateContainer();

Label lbl = new Label();

lbl.Text = e.Row.Cells.GetNamedItem("TICKER").Text + " Test";

lbl.Attributes.Add("onmouseover", "ShowWebCallOut()");

cell.Controls.Add(lbl);

}
All times are GMT -5. The time now is 11:55 AM.
Previous Next