S
Smidge Boyter
I have a MDI Child form with various controls and a panel. On the panel at
runtime I am adding a form to the panel. Everything works except when the
outer form is resized, the panel gets resized but the form on the panel
doesn't. It just stays in the same place that it starts out on. Below is
my code that is adding the form to the panel.
Any ideas?
mfrmProdSearch = new frmProductSearch();
mfrmProdSearch.TopLevel=false;
mfrmProdSearch.FormBorderStyle = FormBorderStyle.None;
mfrmProdSearch.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
mfrmProdSearch.Anchor = System.Windows.Forms.AnchorStyles.Top;
mfrmProdSearch.Anchor = System.Windows.Forms.AnchorStyles.Right;
mfrmProdSearch.Anchor = System.Windows.Forms.AnchorStyles.Left;
pnlMLProducts.Controls.Add(mfrmProdSearch);
mfrmProdSearch.Show();
runtime I am adding a form to the panel. Everything works except when the
outer form is resized, the panel gets resized but the form on the panel
doesn't. It just stays in the same place that it starts out on. Below is
my code that is adding the form to the panel.
Any ideas?
mfrmProdSearch = new frmProductSearch();
mfrmProdSearch.TopLevel=false;
mfrmProdSearch.FormBorderStyle = FormBorderStyle.None;
mfrmProdSearch.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
mfrmProdSearch.Anchor = System.Windows.Forms.AnchorStyles.Top;
mfrmProdSearch.Anchor = System.Windows.Forms.AnchorStyles.Right;
mfrmProdSearch.Anchor = System.Windows.Forms.AnchorStyles.Left;
pnlMLProducts.Controls.Add(mfrmProdSearch);
mfrmProdSearch.Show();