LinqUtilsCoerceToType Method  | 
 
            Coerces the linq expression to the targettype.
            
 
    Namespace: 
   SD.LLBLGen.Pro.LinqSupportClasses
    Assembly:
   SD.LLBLGen.Pro.ORMSupportClasses (in SD.LLBLGen.Pro.ORMSupportClasses.dll) Version: 5.11.0.0 (5.11.23.1114)
Syntaxpublic static Expression CoerceToType(
	Expression toCoerce,
	Type targetType
)
Public Shared Function CoerceToType ( 
	toCoerce As Expression,
	targetType As Type
) As Expression
Parameters
- toCoerce
 - Type: System.Linq.ExpressionsExpression
To coerce. - targetType
 - Type: SystemType
Type of the target. 
Return Value
Type: 
ExpressiontoCoerce if toCoerce's type is equal to targetType, otherwise it's wrapped in a Convert
See Also