コード例 #1
0
 private void btnEditStockInventory_Click(object sender, EventArgs e)
 {
     try
     {
         ProcurementStockTransactionDetailUI loStockTransactionDetail = new ProcurementStockTransactionDetailUI(dgvDetailStockInventory.CurrentRow.Cells["Id"].Value.ToString(),
                                                                                                                dgvDetailStockInventory.CurrentRow.Cells["StockId"].Value.ToString(),
                                                                                                                dgvDetailStockInventory.CurrentRow.Cells["LocationId"].Value.ToString(),
                                                                                                                decimal.Parse(dgvDetailStockInventory.CurrentRow.Cells["POQty"].Value.ToString()),
                                                                                                                decimal.Parse(dgvDetailStockInventory.CurrentRow.Cells["QtyIn"].Value.ToString()),
                                                                                                                decimal.Parse(dgvDetailStockInventory.CurrentRow.Cells["QtyVariance"].Value.ToString()),
                                                                                                                decimal.Parse(dgvDetailStockInventory.CurrentRow.Cells["UnitPrice"].Value.ToString()),
                                                                                                                dgvDetailStockInventory.CurrentRow.Cells["DiscountId"].Value.ToString(),
                                                                                                                decimal.Parse(dgvDetailStockInventory.CurrentRow.Cells["DiscountAmount"].Value.ToString()),
                                                                                                                decimal.Parse(dgvDetailStockInventory.CurrentRow.Cells["TotalPrice"].Value.ToString()),
                                                                                                                dgvDetailStockInventory.CurrentRow.Cells["Remarks"].Value.ToString());
         loStockTransactionDetail.ParentList = this;
         loStockTransactionDetail.ShowDialog();
     }
     catch (Exception ex)
     {
         ErrorMessageUI em = new ErrorMessageUI(ex.Message, this.Name, "btnEditStockInventory_Click");
         em.ShowDialog();
         return;
     }
 }
コード例 #2
0
 private void btnAddStockInventory_Click(object sender, EventArgs e)
 {
     try
     {
         ProcurementStockTransactionDetailUI loStockTransactionDetail = new ProcurementStockTransactionDetailUI();
         loStockTransactionDetail.ParentList = this;
         loStockTransactionDetail.ShowDialog();
     }
     catch (Exception ex)
     {
         ErrorMessageUI em = new ErrorMessageUI(ex.Message, this.Name, "btnAddStockInventory_Click");
         em.ShowDialog();
         return;
     }
 }