Panel.Dock Fill ignoring other Panel.Dock setting

后端 未结 10 1091
我寻月下人不归
我寻月下人不归 2020-12-04 06:02

If you create a panel on a form and set it to Dock=Top and drop another panel and set its Dock=Fill, it may fill the entire form, ignoring the first panel. Changing the tab

10条回答
  •  日久生厌
    2020-12-04 06:21

    Another, potentially cleaner option is to use the TableLayout control. Set up one row of the desired height for your top dock, and another row to fill 100% for your bottom. Set both panels inside to Fill, and you're done.

    (TableLayout does take some getting used to, though.)

提交回复
热议问题