Signature (Visual Basic / VBA)
Public Function BlankToValue( _
ByVal vValue As Variant _
, ByVal vReplace As Variant _
) As Variant
Code Example
BlankToValue("", "NONE") = "NONE"
BlankToValue(Null, "NONE") = "NONE"
BlankToValue("Word", "NONE") = "Word"
BlankToValue(Null, 456) = 456
BlankToValue(123, 456) = 123
Parameters
| Parameter | Description |
|---|---|
| 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. |