int iIndex;
Button[] btns = new Button[3];
for (iIndex = 1; iIndex <= 2; iIndex++)
{
btns[iIndex] = new Button();
btns[iIndex].Left = button1.Left;
btns[iIndex].Top = button1.Top + 100;
btns[iIndex].Visible = true;
this.Controls.Add(btns[iIndex]);
}
供大家学习之用,如有更好的,请多多指教!!!
本文介绍了一种在程序中创建多个按钮的方法,并详细说明了如何设置这些按钮的位置与可见性,以便于用户界面的设计。
1075

被折叠的 条评论
为什么被折叠?



