Cannot get FlowLayoutPanel for extension.

I have a FlowLayoutPanel and I am constantly adding controls to it. They all work, yes, life is beautiful.

But when the container falls into its borders, it remains the same. Now I understand that I can do this with scrollbars, but I don't want that. I want the FlowLayoutPanel to grow in size based on the added controls. Any ideas?

By the way, I have AutoSize mode set to true. It does nothing.

+3
source share
1 answer

I added FlowLayoutPanelin Form. I added a button with the following handler Click:

private void button1_Click(object sender, EventArgs e)
{
    this.flowLayoutPanel1.Controls.Add(new Button());
}

FLP FlowDirection TopDown AutoSize true. BorderStyle FixedSingle, , .

, , FLP. , FLP.

, , , Form, AutoSize true Form .

, , .

+2

Source: https://habr.com/ru/post/1761834/


All Articles