C# Winfrom 窗体上动态生成控件慢处理
2021-01-27 15:13
标签:new pre vat nbsp winfrom style click ESS add 处理方式:布局挂起 C# Winfrom 窗体上动态生成控件慢处理 标签:new pre vat nbsp winfrom style click ESS add 原文地址:https://www.cnblogs.com/YYkun/p/11929152.htmlpanelContent.SuspendLayout();
panelContent.ResumeLayout();
private void button1_Click(object sender, EventArgs e)
{
panelContent.SuspendLayout();
this.panelContent.Controls.Clear();
string aa = DateTime.Now.ToString();
int k = 1;
for (int j = 0; j 200; j++)
{
Add(new QueueButton(), k, this.panelContent, 16, "18.00", "19.00", "Pm");
k++;
}
panelContent.ResumeLayout();
string bb = DateTime.Now.ToString();
MessageBox.Show(aa+"\r\n"+bb);
}
文章标题:C# Winfrom 窗体上动态生成控件慢处理
文章链接:http://soscw.com/index.php/essay/47801.html