Search code examples
.netwinformstablelayoutpanel

How can I achieve a three column layout in a Windows Form?


I am striving for a three column layout in a Windows Form, with a fixed size central column, and two autosizing side columns, so when the form resizes, the centre column is always in the centre, and the two side columns always take up half each of the remaining space.

I have tried this with a TableLayoutPanel, but as soon as I set the middle column to fixed and the outer two to autosize, one of the side columns vanishes from the designer.


Solution

  • Setting the two side columns to 50% and the middle column to a fixed size should do the trick.