private static object ConvertDecimalField(object value) { object convertedValue; if (value == DBNull.Value) { convertedValue = DBNull.Value; } else { var decimalField = (DecimalField)value; var stringValue = decimalField.StringValue; OracleNumber oracleNumber; if (stringValue != null) { oracleNumber = OracleNumber.Parse(stringValue); } else { oracleNumber = new OracleNumber(decimalField.DecimalValue); } convertedValue = oracleNumber; } return(convertedValue); }
object ConvertToOracleNumber(Type type, string value, ref string errorMsg) { return(OracleNumber.Parse(value)); }