1.添加SplitContainer控件放置到主窗体中。右边可以的Panel中可以添加按钮或是树形控件。
2.将子窗体添加到右边的面板中。代码如下FrmAddOrder frmChild = new FrmAddOrder();
frmChild .MdiParent = this; this.splitContainer1.Panel2.Controls.Add(frmChild ); frmChild .Show();
本文详细介绍了如何在主窗体中添加SplitContainer控件,并将子窗体添加到右边面板的方法,适用于需要灵活调整窗口布局的场景。
1.添加SplitContainer控件放置到主窗体中。右边可以的Panel中可以添加按钮或是树形控件。
2.将子窗体添加到右边的面板中。代码如下FrmAddOrder frmChild = new FrmAddOrder();
frmChild .MdiParent = this; this.splitContainer1.Panel2.Controls.Add(frmChild ); frmChild .Show();

被折叠的 条评论
为什么被折叠?