Beispiel #1
0
        private void rbCtrlCompany_Click(object sender, EventArgs e)
        {
            string selectedPage = (sender as RibbonControl).SelectedPage.Name.ToString();

            switch (selectedPage)
            {
            case "CreateCompany":

                splitContainerControl1.Panel2.Controls.RemoveByKey("OpenCompany");

                Company.NewCompany frm = new Company.NewCompany(this);

                frm.Owner    = this;
                frm.TopLevel = false;
                splitContainerControl1.Panel2.Controls.Add(frm);
                frm.Show();
                break;

            case "OpenCompany":

                splitContainerControl1.Panel2.Controls.RemoveByKey("NewCompany");

                Company.OpenCompany frmOpen = new Company.OpenCompany(this.frm);

                frmOpen.Owner    = this;
                frmOpen.TopLevel = false;
                splitContainerControl1.Panel2.Controls.Add(frmOpen);
                frmOpen.Show();
                break;

            default:
                break;
            }
        }
Beispiel #2
0
        private void CompanyMenu_Load(object sender, EventArgs e)
        {
            Company.NewCompany frm = new Company.NewCompany(this);

            frm.Owner    = this;
            frm.TopLevel = false;
            splitContainerControl1.Panel2.Controls.Add(frm);
            frm.Show();
        }
Beispiel #3
0
        private void btnCreateComp_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            Company.NewCompany frm = new Company.NewCompany(this);

            frm.Owner    = this;
            frm.TopLevel = false;
            splitContainerControl1.Panel2.Controls.Add(frm);
            frm.Show();
        }