示例#1
0
        private void btnEntite_Click(object sender, EventArgs e)
        {
            this.splitContainer1.Panel2.Controls.Clear();

            if (Factory.ValUser == 0)//Utilisateur Provincial
            {
                VilleTerritoireForm pvt = new VilleTerritoireForm();
                pvt.Parent = this.splitContainer1.Panel2;
                this.splitContainer1.Panel2.Controls.Add(pvt);
            }
            else if (Factory.ValUser == 1 || Factory.ValUser == 2)//Utilisateur Serveur Central sur Serveur Provincial
            {
                ProvinceForm pvt1 = new ProvinceForm();
                pvt1.Parent = this.splitContainer1.Panel2;
                this.splitContainer1.Panel2.Controls.Add(pvt1);
            }
        }
示例#2
0
        private void lblVilleTer_Click(object sender, EventArgs e)
        {
            this.splitContainer1.Panel2.Controls.Clear();

            if (Factory.ValUser == 0)//Utilisateur Provincial
            {
                VilleTerritoireForm pvt = new VilleTerritoireForm();
                pvt.Parent = this.splitContainer1.Panel2;
                this.splitContainer1.Panel2.Controls.Add(pvt);
            }
            else if (Factory.ValUser == 1 || Factory.ValUser == 2)//Utilisateur Serveur Central sur Serveur Provincial
            {
                ProvinceForm pvt1 = new ProvinceForm();
                pvt1.Parent = this.splitContainer1.Panel2;
                this.splitContainer1.Panel2.Controls.Add(pvt1);
            }
            unitialiseLabels();
            ((Control)lblVilleTer).BackColor = Color.Silver;
            ((Control)lblVilleTer).ForeColor = Color.WhiteSmoke;
        }