Ejemplo n.º 1
0
        private void dgvCallDetails_CellContentDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (dgvCallDetails.Rows[dgvCallDetails.CurrentRow.Index].Cells["Status"].Value.ToString() == "Completed")
            {
                MessageBox.Show("Call already updated.");
                return;
            }
            string     ProductID  = dgvCallDetails.Rows[dgvCallDetails.CurrentRow.Index].Cells["ProductId"].Value.ToString();
            string     CustomerID = dgvCallDetails.Rows[dgvCallDetails.CurrentRow.Index].Cells["CustomerId"].Value.ToString();
            string     CallId     = dgvCallDetails.Rows[dgvCallDetails.CurrentRow.Index].Cells["CallLogId"].Value.ToString();
            frmAddCall obj        = new frmAddCall(ProductID, CustomerID, CallId, "frmMDI");

            obj.ShowDialog();
        }
Ejemplo n.º 2
0
        private void UpdateToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (dgvCallList.Rows[dgvCallList.CurrentRow.Index].Cells["Status"].Value.ToString() == "Completed")
            {
                MessageBox.Show("Call already updated.");
                return;
            }
            string     ProductID  = dgvCallList.Rows[dgvCallList.CurrentRow.Index].Cells[2].Value.ToString();
            string     CustomerID = dgvCallList.Rows[dgvCallList.CurrentRow.Index].Cells[1].Value.ToString();
            string     CallId     = dgvCallList.Rows[dgvCallList.CurrentRow.Index].Cells[0].Value.ToString();
            frmAddCall obj        = new frmAddCall(ProductID, CustomerID, CallId, "frmCallList");

            obj.ShowDialog();
        }
Ejemplo n.º 3
0
 private void deleteToolStripMenuItem_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvProductDetails.CurrentRow.Index > -1)
         {
             DataGridViewRow row = dgvProductDetails.Rows[dgvProductDetails.CurrentCell.RowIndex];
             frmAddCall      obj = new frmAddCall(row.Cells[0].Value.ToString(), model.CustId, "0", "frmListOfProduct");
             obj.ShowDialog();
         }
     }
     catch (Exception EX)
     {
         MessageBox.Show(EX.Message);
         //throw;
     }
 }
Ejemplo n.º 4
0
 private void updateCallToolStripMenuItem_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvCallDetails.Rows[dgvCallDetails.CurrentRow.Index].Cells["Status"].Value.ToString() == "Completed")
         {
             MessageBox.Show("Call already updated.");
             return;
         }
         string     ProductID  = dgvCallDetails.Rows[dgvCallDetails.CurrentRow.Index].Cells[2].Value.ToString();
         string     CustomerID = dgvCallDetails.Rows[dgvCallDetails.CurrentRow.Index].Cells[1].Value.ToString();
         string     CallId     = dgvCallDetails.Rows[dgvCallDetails.CurrentRow.Index].Cells[0].Value.ToString();
         frmAddCall obj        = new frmAddCall(ProductID, CustomerID, CallId, "frmListOfProduct");
         obj.ShowDialog();
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }