private void btnNew_Click(object sender, EventArgs e)
        {
            AttachmentChequeForm form = new AttachmentChequeForm(-1, _chequeId);

            form.ShowDialog();
            fillGrid();
        }
 private void btnDisplay_Click(object sender, EventArgs e)
 {
     if (dataGridView1.SelectedRows.Count > 0)
     {
         DataGridViewRow      dr   = dataGridView1.SelectedRows[0];
         int                  id   = int.Parse(dr.Cells[AttachmentChequeEntity.FIELD_ID].Value.ToString());
         AttachmentChequeForm form = new AttachmentChequeForm(id, _chequeId);
         form.ShowDialog();
         fillGrid();
     }
 }
        private void dataGridView1_DoubleClick(object sender, EventArgs e)
        {
            DataGridView gv = (DataGridView)sender;

            if (gv.SelectedRows.Count <= 0)
            {
                return;
            }

            DataGridViewRow dr = gv.SelectedRows[0];
            int             id = -1;

            id = int.Parse(dr.Cells[AttachmentChequeEntity.FIELD_ID].Value.ToString());
            AttachmentChequeForm form = new AttachmentChequeForm(id, _chequeId);

            form.ShowDialog();
            fillGrid();
        }