关于 tablecell 及其控件集合的问题
我有一个表(System.Web.UI.WebControls)。每行有三个单元格。 在单元格的控件集合中,我放置了一些控件,
TableCell cell = new TableCell();
cell.Font.Bold = false;
cell.BackColor = Color.FromName("lightblue");
cell.Controls.Add(new LiteralControl("Дата"));
row.Cells.Add(cell);
TableCell c3 = new TableCell();
c3.Controls.Add(new CheckBox());
r.Cells.Add(c3);
我看到 CheckBox 存储了一个值,但我不知道如何获取它。你能告诉我怎么做吗?
i have a table (System.Web.UI.WebControls). each row does have three cells.
in cells' controls collection i placed some controls
TableCell cell = new TableCell();
cell.Font.Bold = false;
cell.BackColor = Color.FromName("lightblue");
cell.Controls.Add(new LiteralControl("Дата"));
row.Cells.Add(cell);
TableCell c3 = new TableCell();
c3.Controls.Add(new CheckBox());
r.Cells.Add(c3);
i cant find the way to get values which this controls are holding
i see that CheckBox stores a value, but i don't know how to get it. Can you tell me how?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你需要像这样投射它:
You need to cast it, like this: