private void btnCheckout_Click(object sender, EventArgs e) { Menu panel = new Menu(); //called the Menu form to allow me to call the panel from that form. panel.pnlContent.Controls.Clear(); //I wanted to clear the content of a panel panel.pnlContent.Controls.Add(new Checkout()); //add a new user control to the panel }
Menu
Form
panel.Show();
panel.ShowDialog();
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)