Beispiel #1
0
        private void ReqCancelView_CellValueChanged(object sender, DevExpress.XtraGrid.Views.Base.CellValueChangedEventArgs e)
        {
            decimal dBQty = Convert.ToDecimal(clsStatics.IsNullCheck(ReqCancelView.GetFocusedRowCellValue("HiddenQty"), clsStatics.datatypes.vartypenumeric));
            decimal dCQty = Convert.ToDecimal(clsStatics.IsNullCheck(ReqCancelView.GetFocusedRowCellValue("CancelQty"), clsStatics.datatypes.vartypenumeric));

            if (dCQty > 0)
            {
                if (dBQty != dCQty)
                {
                    MessageBox.Show("Enter Valid Quantity!", "Information", MessageBoxButtons.OK, MessageBoxIcon.Information);
                    ReqCancelView.SetRowCellValue(ReqCancelView.FocusedRowHandle, "CancelQty", "0.00000");
                    return;
                }
            }
        }