GeneralUtilsConvertValueToRealNullIfRequired Method |
Converts the value passed in to null/Nothing (reference type) or default value (value type) if the value is DbNull.Value, based on the type passed
in, also if that type is a nullable type.
Namespace: SD.LLBLGen.Pro.ORMSupportClassesAssembly: SD.LLBLGen.Pro.ORMSupportClasses (in SD.LLBLGen.Pro.ORMSupportClasses.dll) Version: 5.0.0.0 (5.0.0)
Syntax public static Object ConvertValueToRealNullIfRequired(
Object rawValue,
Type destinationType
)
Public Shared Function ConvertValueToRealNullIfRequired (
rawValue As Object,
destinationType As Type
) As Object
Parameters
- rawValue
- Type: SystemObject
The raw value. - destinationType
- Type: SystemType
Type of the destination.
Return Value
Type:
ObjectrawValue if rawValue isn't null/DBNull.Value, otherwise null, if destinationType is reference type, otherwise the default for the
value type
See Also