Exemplo n.º 1
0
 private void dgvBills_CellClick(object sender, DataGridViewCellEventArgs e)
 {
     if (dgvadvanceReceipt.SelectedCells.Count > 0 && e.RowIndex != -1 && dgvadvanceReceipt.Columns[e.ColumnIndex].Name != "Action")
     {
         string     orderID       = dgvadvanceReceipt.CurrentRow.Cells["OrderID"].Value.ToString();
         string     status        = dgvadvanceReceipt.CurrentRow.Cells["Status"].Value.ToString();
         OrderEntry frmOrderEntry = new OrderEntry(orderID, status);
         frmOrderEntry.OnClose += GenerateAdvancePaymentList;
         frmOrderEntry.ShowDialog();
     }
 }
Exemplo n.º 2
0
 private void dgvBills_CellClick(object sender, DataGridViewCellEventArgs e)
 {
     if (dgvBills.SelectedCells.Count > 0 && e.RowIndex != -1 && dgvBills.Columns[e.ColumnIndex].Name != "Action")
     {
         if (UserTools._IsEdit)
         {
             string     orderID       = dgvBills.CurrentRow.Cells["OrderID"].Value.ToString();
             string     status        = dgvBills.CurrentRow.Cells["Status"].Value.ToString();
             OrderEntry frmOrderEntry = new OrderEntry(orderID, status);
             frmOrderEntry.OnClose += GenerateOrderList;
             frmOrderEntry.ShowDialog();
         }
         else
         {
             MessageBox.Show("Permission Denied", "Edit", MessageBoxButtons.OK, MessageBoxIcon.Stop);
         }
     }
 }
Exemplo n.º 3
0
 private void dgvEstimate_CellContentClick(object sender, DataGridViewCellEventArgs e)
 {
     if (dgvEstimate.Columns[e.ColumnIndex].Name == "Action" && e.RowIndex != -1)
     {
         IsLedgerSuccess = true;
         mcustomername   = dgvEstimate.CurrentRow.Cells["PartyName"].Value.ToString();
         string estimateno = dgvEstimate.CurrentRow.Cells["EstimateNo"].Value.ToString();
         string estimateid = dgvEstimate.CurrentRow.Cells["Estimateid"].Value.ToString();
         if (!IsexsistCustomer(mcustomername))
         {
             IsLedgerSuccess = false;
             LedgerDetails ledgerdetails = new LedgerDetails(LedgerDetails._LedgerCategory.Customer, LedgerDetails._Type.showDialog, estimateid, "estimate");
             ledgerdetails.OnClose += Ledgerdetails_OnClose;
             ledgerdetails.ShowDialog();
         }
         if (IsLedgerSuccess)
         {
             OrderEntry orderentry = new OrderEntry(estimateid, mcustomername, estimateno);
             orderentry.ShowDialog();
         }
     }
 }