I have a small program that has a flowLayoutpanel1
I am placing a number od fynamically created labels in it like so:
but i want these labels to have some kind of gap between each other so they are not touching
and lbl.SetBounds();
does not seem to work here.
This is the code I am testing?
flowLayoutPanel1.Controls.Clear();
int length = 9;
for (int i = 0; i < length; i++)
{
Label lbl = new Label();
lbl.Name = i.ToString();
lbl.Text = "Label " + i.ToString();
lbl.AutoSize = true;
lbl.Font = new Font("Ariel", 10);
lbl.SetBounds(0, 20, 70, 70);
lbl.BorderStyle = BorderStyle.FixedSingle;
flowLayoutPanel1.Controls.Add(lbl);
}
Any suggestions on how to get the spacing done?