<-- Previous || Up || Next -->

Blank To Value Function
Convert Values Class

Public Function BlankToValue( _
      ByVal vValue As Variant _
    , ByVal vReplace As Variant _
    ) As Variant

Replace Empty, Null, and empty String values with some other value.
Leave all other types of values unchanged.

Examples:
    BlankToValue("", "NONE") = "NONE"
    BlankToValue(Null, "NONE") = "NONE"
    BlankToValue("Word", "NONE") = "Word"
    BlankToValue(Null, 456) = 456
    BlankToValue(123, 456) = 123
See also:
    BlankToNull Function
    NullValue Property
vValue: The value which is to be replaced in certain limited cases. Function returns vReplace is vValue is Empty, Null, or an empty string. Function returns vValue unchanged in all other cases.
vReplace: The value which is to replace that of vValue in certain cases.

Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.