RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
Variants.NullStrictConvert Variable

Specifies whether Null conversion is an error.

Pascal
NullStrictConvert: Boolean = True;
C++
Boolean NullStrictConvert = True;

Variants

NullStrictConvert determines the outcome of attempts to convert Null variants to other types. If NullStrictConvert is true (default), attempting to convert a Null variant raises a EVariantTypeCastError, unless the conversion is to a custom variant that defines a conversion from Null. If NullStrictConvert is false, then conversion from Null follows the following rules:

Destination 
Conversion result 
Numeric type  
Zero  
String type  
Value of NullAsStringValue global variable. (Default: empty string.)  
Boolean  
False.  

 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!