The CDbl function is used to perform conversions from other data types to the internationally recognized format of the Double subtype. For example, the recognition of decimal separators and thousands separators depends on the system's regional settings. CDbl function
Returns an expression that has been converted to a Variant of Double subtype.
CDbl(expression)
The expression parameter is any valid expression.
illustrate
Typically, you use subtype data conversion functions to write code to show that the results of certain operations should be expressed as a specific data type instead of the default data type. For example, in the case of monetary or integer arithmetic, use the CDbl or CSng function to force double-precision or single-precision arithmetic.
The CDbl function is used to perform conversions from other data types to the internationally recognized format of the Double subtype. For example, the recognition of decimal separators and thousands separators depends on the system's regional settings.
The following example uses the CDbl function to convert expression to Double.
Dim MyCurr, MyDouble
MyCurr = CCur(234.456784) ' MyCurr is Currency type (234.4567).
MyDouble = CDbl(MyCurr * 8.2 * 0.01) ' Convert the result to Double type (19.2254576).