Skip to content

EF.VariantUtils

Variant-related utility routines.

Routines

pascal
function EFVarToStr(const AVariant: Variant): string;

Converts AVariant to a string, returning '' for null/empty variants.

pascal
function EFVarToDateTime(const AVariant: Variant): TDateTime;

Converts AVariant to a TDateTime, returning 0 for null/empty variants.

pascal
function EFVarToInt(const AVariant: Variant): Integer;

Converts AVariant to an Integer, returning 0 for null/empty variants.

pascal
function EFVarIsEmpty(const AVariant: Variant): Boolean;

Check if a Variant value is an Empty Value

pascal
function EFVarIsEmptyString(const AVariant: Variant): Boolean;

Check if a Variant value is an Empty String

pascal
function EFVarToBoolean(const AVariant: Variant): Boolean;

Converts AVariant to a Boolean, returning False for null/empty variants.

pascal
function EFVarToFloat(const AVariant: Variant): Double;

Converts AVariant to a Double, returning 0 for null/empty variants.

pascal
function EFVarToCurrency(const AVariant: Variant): Currency;

Converts AVariant to a Currency, returning 0 for null/empty variants.

pascal
function IsRange(const AFrom, ATo: Variant): Boolean;

Returns True if ATo is greater than or equal to AFrom, and False otherwise. If one or both values are not Null, the function returns True.

Released under Apache License, Version 2.0.