Problems with FlowLayoutPanel inside Panel with AutoSize

Posted by DxCK on Stack Overflow See other posts from Stack Overflow or by DxCK
Published on 2010-04-09T22:17:34Z Indexed on 2010/04/10 8:53 UTC
Read the original article Hit count: 811

Filed under:
|
|
|
|

I have the following controls hierarchy:

Form
  Panel (AutoSize = true, AutoSizeMode = GrowAndShrink, Dock = Top)
    FlowLayoutPanel (AutoSize = true, AutoSizeMode = GrowAndShrink, Dock = Top)
      Control1, Control2, Control3, Control4, ...
    FlowLayoutPanel (AutoSize = true, AutoSizeMode = GrowAndShrink, Dock = Top)
      Control1, Control2, Control3, Control4, ...

Here is how it layouts in various sizes:

Fully visible all 8 buttons, but the Panel forgot to shrink

Fully visible all 8 buttons, but the Panel forgot to shrink

The first FlowLayoutPanel are fully visible, but the second is only half visible, button8 is missing

The first FlowLayoutPanel are fully visible, but the second is only half visible, button8 is missing

The first FlowLayoutPanel are fully visible, but the second is only half visible, button7 and button8 are missing

The first FlowLayoutPanel are fully visible, but the second is only half visible, button7 and button8 are missing

The first FlowLayoutPanel are fully visible, but the second is only quarter visible, button 6, button7 and button8 are missing

The first FlowLayoutPanel are fully visible, but the second is only quarter visible, button 6, button7 and button8 are missing

As you see, i'm not satisfied from this behavior. Is there something i can do to get all this work?

© Stack Overflow or respective owner

Related posts about c#

Related posts about .NET