Esempio n. 1
0
 private void btnInsert_Click(object sender, EventArgs e)
 {
     FrmFigureEdit frmedit = new FrmFigureEdit();
     FrmFigureEdit.IdFigureEdit = 0;
     frmedit.ShowDialog();
     FillToGrid();
 }
Esempio n. 2
0
        private void btnInsert_Click(object sender, EventArgs e)
        {
            FrmFigureEdit frmedit = new FrmFigureEdit();

            FrmFigureEdit.IdFigureEdit = 0;
            frmedit.ShowDialog();
            FillToGrid();
        }
Esempio n. 3
0
 private void btnEdit_Click(object sender, EventArgs e)
 {
     if ((lblID.Text == "") || (lblID.Text == "0"))
     {
         MessageBox.Show("Bạn hãy chọn phác đồ cần sửa!");
         return;
     }
     FrmFigureEdit.IdFigureEdit = int.Parse(lblID.Text);
     FrmFigureEdit frmedit = new FrmFigureEdit();
     frmedit.ShowDialog();
     FillToGrid();
 }
Esempio n. 4
0
        private void btnEdit_Click(object sender, EventArgs e)
        {
            if ((lblID.Text == "") || (lblID.Text == "0"))
            {
                MessageBox.Show("Bạn hãy chọn phác đồ cần sửa!");
                return;
            }
            FrmFigureEdit.IdFigureEdit = int.Parse(lblID.Text);
            FrmFigureEdit frmedit = new FrmFigureEdit();

            frmedit.ShowDialog();
            FillToGrid();
        }
Esempio n. 5
0
        private void grd_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (e.RowIndex == -1)
            {
                return;
            }
            if (grd.Rows[e.RowIndex].Cells["idDataGridViewTextBoxColumn"].Value == null)
            {
                IdFigure = 0;
            }

            else
            {
                IdFigure = int.Parse(grd.Rows[e.RowIndex].Cells["idDataGridViewTextBoxColumn"].Value.ToString());
            }
            lblID.Text = IdFigure.ToString();

            FrmFigureEdit.IdFigureEdit = IdFigure;
            FrmFigureEdit frmEdit = new FrmFigureEdit();

            frmEdit.ShowDialog();
            FillToGrid();
        }
Esempio n. 6
0
        private void grd_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (e.RowIndex == -1) return;
            if (grd.Rows[e.RowIndex].Cells["idDataGridViewTextBoxColumn"].Value == null)
            {
                IdFigure = 0;
            }

            else
            {
                IdFigure = int.Parse(grd.Rows[e.RowIndex].Cells["idDataGridViewTextBoxColumn"].Value.ToString());
            }
            lblID.Text = IdFigure.ToString();

            FrmFigureEdit.IdFigureEdit = IdFigure;
            FrmFigureEdit frmEdit = new FrmFigureEdit();
            frmEdit.ShowDialog();
            FillToGrid();
        }