private void productButton_Click(object sender, EventArgs e) { // Set active bar pnlHomeBar.Visible = false; pnlAgtBar.Visible = false; pnlPackBar.Visible = false; pnlProdBar.Visible = true; pnlSuppBar.Visible = false; // Set the active font color homeButton.ForeColor = Color.Black; agentButton.ForeColor = Color.Black; packageButton.ForeColor = Color.Black; productButton.ForeColor = Color.MintCream; supplierButton.ForeColor = Color.Black; // Reset all other forms homeFormOpened = false; pkgFormOpened = false; suppsFormOpened = false; agtFormOpened = false; if (prodsFormOpened == false) { // Hide all other forms homeForm.Hide(); agtForm.Hide(); pkgForm.Hide(); suppsForm.Hide(); prodsForm.MdiParent = this; prodsForm.Dock = DockStyle.Fill; prodsForm.Show(); prodsFormOpened = true; } }
private void ProductsBtn_Click(object sender, EventArgs e) { frmProducts pr = new frmProducts(); pr.Show(); }