if (e.Cell.Column.Key == nameof(DicDrugUnit.DgCnvRate) || e.Cell.Column.Key == nameof(DicDrugUnit.DgUnit)) { var data = dgvUnitInfo.Grid.ActiveRow.ListObject as DicDrugUnit; if (data == null || data.DgCnvRate == null || data.DgUnit == null) { return; } data.DgCnvResult = $"1{GetDicHisNameByCode(DicTypeCodeDefine.DRUG_UNIT, data.DgUnit)}={data.DgCnvRate}{data.DgBasicUnit}"; }