for (int i = 1; i <= 2; i++) { TableRow rw = new TableRow(); TableCell emp = new TableCell(); TableCell code = new TableCell(); TableCell department = new TableCell(); TableCell tl = new TableCell(); tl.ColumnSpan = 23; TableCell hours = new TableCell(); emp.Text = "damian hawkes"; code.Text = "543210"; department.Text = "IT"; Table timeline = new Table(); TableRow rw1 = new TableRow(); TableRow rw2 = new TableRow(); TableRow rw3 = new TableRow(); TableCell cell1 = new TableCell(); TableCell cell2 = new TableCell(); TableCell cell3 = new TableCell(); DateTime dt = DateTime.Today.Date; for (int x = 1; x <= 720; x++) { cell1.ID = dt.Hour + ":" + dt.Minute + ":" + dt.Second; cell2.ID = dt.Hour + ":" + dt.Minute + ":" + dt.Second; cell3.ID = dt.Hour + ":" + dt.Minute + ":" + dt.Second; cell3.ToolTip = dt.Hour + ":" + dt.Minute + ":" + dt.Second; cell2.ToolTip = dt.Hour + ":" + dt.Minute + ":" + dt.Second; cell1.ToolTip = dt.Hour + ":" + dt.Minute + ":" + dt.Second; rw1.Cells.Add(cell1); rw2.Cells.Add(cell2); rw3.Cells.Add(cell3); timeline.Rows.Add(rw1); timeline.Rows.Add(rw2); timeline.Rows.Add(rw3); dt = dt.AddMinutes(2.00); } tl.Controls.Add(timeline); hours.Text = "08:00"; rw.Cells.Add(emp); rw.Cells.Add(code); rw.Cells.Add(department); rw.Cells.Add(tl); rw.Cells.Add(hours); table_common_clock.Rows.Add(rw); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)