private void btnAdd_Click(object sender, EventArgs e) { ClientWithPlanner frmClient = new ClientWithPlanner(); frmClient.TopLevel = false; splitContainer.Panel2.Controls.Add(frmClient); frmClient.Dock = DockStyle.Fill; frmClient.Show(); }
private void btnEdit_Click(object sender, EventArgs e) { if (trvList.SelectedNode != null) { Client client = convertSelectedRowDataToClient(); ClientWithPlanner frmClient = new ClientWithPlanner(client); frmClient.TopLevel = false; splitContainer.Panel2.Controls.Add(frmClient); frmClient.Dock = DockStyle.Fill; frmClient.Show(); } }