asp:Table ID="ServerTable" runat="server" Width="100%" Height="100%" CellSpacing="20" > asp:TableRow> asp:TableCell> asp:Table CssClass="HeatTableGreen" ID="Table2" runat="server" Height="100%" width="100%" > asp:TableRow> asp:TableCell CssClass="HeatInfoCell" ID="SvrName1" HorizontalAlign="Center" > label>1</label> /asp:TableCell> asp:TableCell > /asp:TableCell> asp:TableCell > /asp:TableCell> /asp:TableRow> asp:TableRow> asp:TableCell > /asp:TableCell> asp:TableCell CssClass="HeatInfoCell" ID="SvrCount1" HorizontalAlign="Center" > <label>15</label> /asp:TableCell> asp:TableCell > /asp:TableCell> /asp:TableRow> /asp:Table> /asp:TableCell> etc etc...There are 9 total of these in a 3x3 table and I think (note the hopeful use of that word) I've got the C# code
var HeatTable = new Table(); if ((i % 2) == 0) { HeatTable.CssClass = ".HeatTableGreen"; } else { HeatTable.CssClass = ".HeatTableYellow"; } HeatTable.ID = "HeatTable" + i.ToString(); for (int k = 0; k < 2; k++) //Row counter in HeatTable { var HeatRow = new TableRow(); for (int j = 0; j < 3; j++) //Col counter in HeatTable { var HeatCell = new TableCell(); switch (k) { case 0: if (j == 0) { //this is a HeatInfo cell HeatCell.Text = "1"; //replace with ServerName from table HeatCell.CssClass = ".HeatInfo"; } break; case 1: if (j == 1) { //the other HeatInfo cell HeatCell.Text = "22"; //replace with CurrentTotalTasks HeatCell.CssClass = ".HeatInfo"; } break; default: HeatCell.CssClass = "HeatCell"; break; } //HeatCell HeatRow.Cells.Add(HeatCell); } //HeatRow HeatTable.Rows.Add(HeatRow); } //HeatTable } HeatFrameRow.Cells.Add(HeatFrameCell); HeatFrame.Rows.Add(HeatFrameRow);But I have no flailing idea how to get this to show up on the page. When I run it, I get a blank page
div id="HTDIv"> asp:Table ID="HeatFrame" runat="server" GridLines="Both" > /divWhat am I not doing?