Ejemplo n.º 1
0
        private void btnAjout_Click(object sender, EventArgs e)
        {
            var Det = new frmDetTypeTest(lvlAcces);

            Det.ShowDialog();
            if (Det.statut == true)
            {
                SelectTypeTest = Det.TypeSelect;
                update();
            }
        }
Ejemplo n.º 2
0
        private void btnCopier_Click(object sender, EventArgs e)
        {
            frmDetTypeTest frmCop;
            TypeTest cop = TypeSelect;
            cop.codeTypeTest = "";

            frmCop = new frmDetTypeTest(cop, false, lvlAcces);
            frmCop.ShowDialog();
            if (frmCop.statut == true)
            {
                TypeSelect = frmCop.TypeSelect;
                this.Close();
            }
            frmCop.Closed += (s, args) => this.Close();
        }
Ejemplo n.º 3
0
        private void modifierType()
        {
            frmDetTypeTest detailTT = new frmDetTypeTest(SelectTypeTest, true, lvlAcces);
            detailTT.ShowDialog();

            if(detailTT.statut == true)
            {
                SelectTypeTest = detailTT.TypeSelect;
                update();
            }
            else
            {
                int index = gestionTypeTest.RowByCode(SelectTypeTest.codeTypeTest, gridTypeTest);
                if (gridTypeTest.RowCount > (index + 1))
                    SelectTypeTest = (TypeTest)gridTypeTest.Rows[index + 1].Tag;
                else
                    SelectTypeTest = (TypeTest)gridTypeTest.Rows[index - 1].Tag;
                update();
            }
        }