Convert Values Class
Entisoft Tools 2.0 Object Library
Version 2.0.6 Released 1999/11/14 03:27
<-- Previous || Index || Main || Topics || Next -->Declarations Section, EmptyValue Property, NullValue Property, BlankToNull Function, BlankToValue Function, CBoolIgnErr Function, CByteIgnErr Function, CCurIgnErr Function, CDateIgnErr Function, CDblIgnErr Function, CDecIgnErr Function, CIntIgnErr Function, CLngIgnErr Function, CSngIgnErr Function, CVarIgnErr Function, CVDateIgnErr Function, EmptyToBlank Function, EmptyToNull Function, EmptyToValue Function, EqualQuotedValue Function, LengthOfType Function, MostCapableDataType Function, NonZeroToTrue Function, NullToBlank Function, NullToValue Function, PromoteToMostCapableDataType Function, ReplaceValue Function, ReplaceValueOfType Function, ReplaceVarTypeWithValue Function, SetVariants Sub, SwapNonObjects Sub, SwapVariants Sub, VariantIsBlank Function, VariantOfType Function, VariantStringToVariant Function, VariantToVariantString Function, VariantToCString Function, VariantToFixedCString Function, VariantToString Function, VariantToVBConstExpression Function, VariantToVBEvalExpression Function
- Declarations Section
- Empty Value Property
- Return an Empty value (a Variant with a VarType of vbEmpty).
- Null Value Property
- Return a Variant of type Null (a Variant with a VarType of vbNull).
- Blank To Null Function
- Replace an empty string with a Null value. Leave all other types of values unchanged.
- Blank To Value Function
- Replace Empty, Null, and empty String values with some other value. Leave all other types of values unchanged.
- C Bool Ign Err Function
- "Convert To Boolean Ignore Errors" Attempt to convert vValue to a Boolean value. Return vValue as a Boolean value if the conversion was successful. Return False if vValue could not be converted to a Boolean.
- C Byte Ign Err Function
- "Convert To Byte Ignore Errors" Attempt to convert vValue to a Byte value. Return vValue as a Byte value if the conversion was successful. Return 0 (zero) if vValue could not be converted to a Byte.
- C Cur Ign Err Function
- "Convert To Currency Ignore Errors" Attempt to convert vValue to a Currency value. Return vValue as a Currency value if the conversion was successful. Return 0 (zero) if vValue could not be converted to a Currency.
- C Date Ign Err Function
- "Convert To Date Ignore Errors" Attempt to convert vValue to a Date value. Return vValue as a Date value if the conversion was successful. Return the Date represented by the number 0 (zero) if vValue could not be converted to a Date.
- C Dbl Ign Err Function
- "Convert To Double Ignore Errors" Attempt to convert vValue to a Double (precision floating-point) value. Return vValue as a Double value if the conversion was successful. Return 0 (zero) if vValue could not be converted to a Double.
- C Dec Ign Err Function
- "Convert To Decimal Ignore Errors" Attempt to convert vValue to a Decimal value. Return vValue as a Decimal value if the conversion was successful. Return Empty if vValue could not be converted to a Decimal.
- C Int Ign Err Function
- "Convert To Integer Ignore Errors" Attempt to convert vValue to an Integer value. Return vValue as an Integer value if the conversion was successful. Return 0 (zero) if vValue could not be converted to an Integer.
- C Lng Ign Err Function
- "Convert To Long Ignore Errors" Attempt to convert vValue to a Long (Integer) value. Return vValue as a Long value if the conversion was successful. Return 0 (zero) if vValue could not be converted to a Long.
- C Sng Ign Err Function
- "Convert To Single Ignore Errors" Attempt to convert vValue to a Single (precision floating-point) value. Return vValue as a Single value if the conversion was successful. Return 0 (zero) if vValue could not be converted to a Single.
- C Var Ign Err Function
- "Convert To Variant Ignore Errors" Attempt to convert vValue to a Variant (either string or numeric) value. Return vValue as a Variant value if the conversion was successful. Return Empty if vValue could not be converted to a Variant.
- CV Date Ign Err Function
- "Convert To Date Ignore Errors" Attempt to convert vValue to a Date value. Return vValue as a Date value if the conversion was successful. Return the Date represented by the number 0 (zero) if vValue could not be converted to a Date.
- Empty To Blank Function
- Replace an Empty value with a blank String. Leave all other types of values unchanged.
- Empty To Null Function
- Replace an Empty value with a Null value. Leave all other types of values unchanged.
- Empty To Value Function
- Replace Empty values with some default value. Leave all other types of values unchanged.
- Equal Quoted Value Function
- Returns the string expression which can be used within a Microsoft SQL WHERE clause to search for the value vValue.
- Length Of Type Function
- Returns the length of the internal representation of any type of value. For Empty and Null variants, returns a length of zero. For other non-strings, the length is the number of bytes occupied by the variable.
- Most Capable Data Type Function
- Returns the VarType of the most CAPABLE of the data types of the two arguments. The most capable data type is the one which has the widest range of values and is capable of representing vOne.
- Non Zero To True Function
- Return true if the argument is a non-zero numeric, date, numeric string, or date string value. Function returns False in all other cases.
- Null To Blank Function
- Replace a Null value with a blank String. Leave all other types of values unchanged.
- Null To Value Function
- Replace Null values with some default value. Leave all other types of values unchanged.
- Promote To Most Capable Data Type Function
- Possibly promotes one of two arguments to the more CAPABLE data type. The most capable data type is the one which has the widest range of values and is capable of representing both arguments.
- Replace Value Function
- "Replace One Value With Another Value" Replaces some specific value with another value. Returns all other values unchanged. Generally only supports numeric and string values.
- Replace Value Of Type Function
- "Replace One Value Of A Specific Type With Another Value" Replaces some specific value of a specific type with another value. Returns all other values unchanged. Generally only supports numeric and string values.
- Replace Var Type With Value Function
- "Replace All Values Of A Specific Type With Another Value" Replaces all values which have a specific data type with another value. Returns all other values unchanged. Generally only supports numeric and string values.
- Set Variants Sub
- Sets one argument to the value of another. Assumes that the arguments are of compatible types.
- Swap Non Objects Sub
- Swap two values that are not Objects or DataObjects. Assumes that the arguments are of compatible types.
- Swap Variants Sub
- Swap two values. Assumes that the arguments are of compatible types.
- Variant Is Blank Function
- Return True if argument is Empty, Null, or a blank String. Function returns False otherwise.
- Variant Of Type Function
- Return a value of the specified data type.
- Variant String To Variant Function
- "Variant String To Variant Value" or "Variant Value From Variant String" Converts from a "Variant String" back to the original value. For the purposes of this function, a "Variant String" is one which represents some type of value and also contains information about the type of value being represented. Inverse of the VariantToVariantString function.
- Variant To Variant String Function
- "Variant Value To Variant String" or "Variant String From Variant Value" Represents any type of value as a "Variant String." For the purposes of this function, a "Variant String" is one which represents some type of value and also contains information about the type of value being represented. Inverse of the VariantStringToVariant function.
- Variant To C String Function
- Convert a value into a C string (a string with a Nil (Chr$(0)) terminating character). This function is usually used to prepare Visual Basic strings for passing to C language DLLs such as the Windows API functions. This function should only be used to pass strings to Windows API functions which cannot possibly lengthen the string.
- Variant To Fixed C String Function
- Create a C string of length vCStringSize and copy vBasicString into it. Normally used to allocate a string with enough space to receive a string value back from Windows API function calls.
- Variant To String Function
- Converts any type of Variant into a string. Null and Empty is converted to a zero-length string.
- Variant To VB Const Expression Function
- "Variant To Visual Basic Constant Expression" Return the string representation of any type of value as it would appear within Visual Basic code.
- Variant To VB Eval Expression Function
- "Variant To Visual Basic Eval Expression" Return the string representation of any type of value as it would appear within a Visual Basic (non-Const) expression. Converts the value of a variant into a string that can be passed to the Eval function (in Access and Excel only).
This Windows-based ActiveX DLL provides many useful routines through its function-bearing and data structure classes. Consult the Help file for more information, or call us at 1-310-472-3736. For the latest news and files, visit our home page on the World Wide Web: http://www.entisoft.com
Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.