在form_load的时候定义了一个button Button button = new System.Windows.Forms.Button();
button.BackColor = System.Drawing.Color.Red;
button.Location = new System.Drawing.Point(65, 108);
button.Name = "button12";
button.Size = new System.Drawing.Size(75, 23);
button.TabIndex = 0;
button.Text = "button12";
this.Controls.Add(button);设置了button.BackColor = System.Drawing.Color.Red,但是程序运行时,这个button的背景色没有改变,请问怎么改变button的背景颜色,谢谢。
button.BackColor = System.Drawing.Color.Red;
button.Location = new System.Drawing.Point(65, 108);
button.Name = "button12";
button.Size = new System.Drawing.Size(75, 23);
button.TabIndex = 0;
button.Text = "button12";
this.Controls.Add(button);设置了button.BackColor = System.Drawing.Color.Red,但是程序运行时,这个button的背景色没有改变,请问怎么改变button的背景颜色,谢谢。
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货