Beispiel #1
0
        private void labelGrid_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            CRUDLabel modifyLabel = new CRUDLabel();

            modifyLabel.crudLID.Text = this.labelGrid.CurrentRow.Cells[0].Value?.ToString() ?? null;
            //modifyLabel.crudLLabelControlName.Text = this.labelGrid.CurrentRow.Cells[2].Value?.ToString() ?? null;

            //modifyLabel.empCombo.Text = this.labelGrid.CurrentRow.Cells[16].Value?.ToString() ?? null;
            modifyLabel.empCombo.Text = this.labelGrid.CurrentRow.Cells[15].Value?.ToString() ?? null;
            //modifyLabel.crudLEmployeeFullName.Text = this.labelGrid.CurrentRow.Cells[15].Value?.ToString() ?? null;
            modifyLabel.crudLEmpID.Text = this.labelGrid.CurrentRow.Cells[1].Value?.ToString() ?? null;

            modifyLabel.subCombo.Text = this.labelGrid.CurrentRow.Cells[16].Value?.ToString() ?? null;
            //modifyLabel.crudLSubjectCode.Text = this.labelGrid.CurrentRow.Cells[16].Value?.ToString() ?? null;
            modifyLabel.crudLSubID.Text = this.labelGrid.CurrentRow.Cells[2].Value?.ToString() ?? null;

            modifyLabel.groupCombo.Text = this.labelGrid.CurrentRow.Cells[17].Value?.ToString() ?? null;
            //modifyLabel.crudLGroupCode.Text = this.labelGrid.CurrentRow.Cells[17].Value?.ToString() ?? null;
            modifyLabel.crudLGroupID.Text = this.labelGrid.CurrentRow.Cells[3].Value?.ToString() ?? null;

            modifyLabel.crudLConcat.Text = this.labelGrid.CurrentRow.Cells[22].Value?.ToString() ?? null;

            modifyLabel.crudLLang.Text   = this.labelGrid.CurrentRow.Cells[18].Value?.ToString() ?? null;
            modifyLabel.crudLLangID.Text = this.labelGrid.CurrentRow.Cells[21].Value?.ToString() ?? null;

            modifyLabel.crudLSem.Text = this.labelGrid.CurrentRow.Cells[19].Value?.ToString() ?? null;

            modifyLabel.crudLFinal.Text = this.labelGrid.CurrentRow.Cells[20].Value?.ToString() ?? null;

            modifyLabel.crudLHL.Text = this.labelGrid.CurrentRow.Cells[4].Value?.ToString() ?? null;
            modifyLabel.crudLHS.Text = this.labelGrid.CurrentRow.Cells[6].Value?.ToString() ?? null;
            modifyLabel.crudLHE.Text = this.labelGrid.CurrentRow.Cells[8].Value?.ToString() ?? null;


            modifyLabel.crudLHLAss.Text = this.labelGrid.CurrentRow.Cells[5].Value?.ToString() ?? null;
            modifyLabel.crudLHSAss.Text = this.labelGrid.CurrentRow.Cells[7].Value?.ToString() ?? null;
            modifyLabel.crudLHEAss.Text = this.labelGrid.CurrentRow.Cells[9].Value?.ToString() ?? null;

            modifyLabel.mailAddress.Text = this.labelGrid.CurrentRow.Cells[23].Value?.ToString() ?? null;

            modifyLabel.FormClosed += UpdateLabelGrid_FormClosed;
            modifyLabel.ShowDialog();
        }
Beispiel #2
0
        private void addLabelBtn_Click(object sender, EventArgs e)
        {
            CRUDLabel modifyLabel = new CRUDLabel();

            modifyLabel.crudLLabelControlName.Text = null;
            modifyLabel.crudLID.Text = null;
            modifyLabel.crudLEmployeeFullName.Text = null;
            modifyLabel.crudLSubjectCode.Text      = null;
            modifyLabel.crudLGroupCode.Text        = null;
            modifyLabel.crudLSem.Text   = null;
            modifyLabel.crudLHLAss.Text = "0";
            modifyLabel.crudLHSAss.Text = "0";
            modifyLabel.crudLHEAss.Text = "0";

            modifyLabel.crudLHL.Text = "0";
            modifyLabel.crudLHS.Text = "0";
            modifyLabel.crudLHE.Text = "0";

            modifyLabel.crudLDelete.Visible = false;
            modifyLabel.FormClosed         += UpdateLabelGrid_FormClosed;
            modifyLabel.ShowDialog();
        }