If you want some dynamic sizing in conjunction with a word-wrapping label you can do the following:
- Put the label inside a panel
Handle the ClientSizeChanged event
for the panel, making the
label fill the space:
private void Panel2_ClientSizeChanged(object sender, EventArgs e)
{
label1.MaximumSize = new Size((sender as Control).ClientSize.Width - label1.Left, 10000);
}
Set Auto-Size
for the label to true
- Set
Dock
for the label to Fill