private void tableLayoutPanel3_Click(object sender, EventArgs e) { var form = new NewPatient { PatientListForm = this, TopLevel = false, Dock = DockStyle.Fill }; CatelogForm.pnlFill.Controls.Clear(); CatelogForm.pnlFill.Controls.Add(form); form.Show(); }
private void btnCreateNew_Click(object sender, EventArgs e) { var form = new NewPatient { MedicalForm = this, TopLevel = false, Dock = DockStyle.Fill, PatientListForm = null }; CatelogForm.pnlFill.Controls.Clear(); CatelogForm.pnlFill.Controls.Add(form); form.Show(); }