The CStr Function

This is the function most used by VBA in implicit data type conversions. It converts a Variant to a String, formatted according to the WRS. When converting a Date type, the ShortDate format is used, as defined in the WRS. Note that when converting Booleans, the resulting text is the English "True" or "False" and is not dependent on any Windows settings. Compare this with the implicit conversion of Booleans, whereby MsgBox "I am " & True results in the True being displayed in the WRS language ("I am Sann" in Norwegian Regional Settings).

0 0

Post a comment