Method: CDbl for VBS
- Updated2024-09-12
- 1 minute(s) read
Methods > Method: CDbl for VBS
Method: CDbl for VBS
Converts an expression into the Variant type with the Double subtype.
vCDbl = Object.CDbl(expression)
Object | VBS Object with this method. You do not need to specify this object. |
expression | Variant Specifies any expression. |
vCDbl | Variant Receives the converted value. During conversion the CDbl method considers the locale settings of your computer, for example decimal points and thousands separators. |
The following example converts a text into a double value:
Call MsgBox(CDbl("22,55")) ' Returns a Double. Result depends on your local settings