Hello,
I need a field of buttons. Actually, i tried a variety of things including array of points, changing 1 point's coordinates, but he still doesn't want to eat line 9. I need that line to work. Or, maybe, there is some other way?
Thanks in advance.
Code:
Button[] btn = new Button[100];
Random rnd = new Random();
Point pt = new Point();
public Form1()
{
InitializeComponent();
for (int i = 0; i < 100; i++)
{
[B]btn[i].Location = new Point(100+25*i, 100);[/B]
btn[i].Height = 25;
btn[i].Width = 25;
}
this.Controls.AddRange(btn);
}
Thanks in advance.
Comment