void dgrdv_CellContentClick(object sender, DataGridViewCellEventArgs e) { int irow = e.RowIndex; int icol = e.ColumnIndex; if ((irow == -1) || (icol == -1)) { return; } long NoteID = (long)this.dtblFineAMT.DefaultView[irow]["NoteID"]; if (this.dgrdv.Columns[icol].Name == this.ColumnbtnEdit.Name) { if (frmOper == null) { frmOper = new FrmFineAMTOper(); new FrmStyle(frmOper).SetPopFrmStyle(this); frmOper.AffterSave += this.LoadData; } frmOper.Edit(NoteID); frmOper.ShowDialog(); } if (this.dgrdv.Columns[icol].Name == this.ColumnbtnConfirm.Name) { if (frmConfirm == null) { frmConfirm = new FrmFineAMTConfirm(); new FrmStyle(frmConfirm).SetPopFrmStyle(this); frmConfirm.AffterSave += this.LoadData; } frmConfirm.ConfirmOper(NoteID); frmConfirm.ShowDialog(); } }
void lnkNew_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { if (frmOper == null) { frmOper = new FrmFineAMTOper(); new FrmStyle(frmOper).SetPopFrmStyle(this); frmOper.AffterSave += this.LoadData; } frmOper.New(); frmOper.ShowDialog(); }