MS Excel: CDBL Function (VBA)
In Microsoft Excel, the CDBL function converts a value to a double.
Syntax
The syntax for the CDBL function is:
CDbl( expression )
expression is the value to convert to a double.
Applies To
- Excel 2011 for Mac, Excel 2010, Excel 2007, Excel 2003, Excel XP, Excel 2000
Type of Function
- VBA function (VBA)
VBA Function Example
The CDBL function can only be used in VBA code. For example:
Dim LDouble As Double LDouble = CDbl(8.45 * 0.005 * 0.01)
The variable called LDouble would now contain the value of 0.0004225.
반응형
'VBA' 카테고리의 다른 글
Excel VBA 이용해서 워드 파일 생성 (0) | 2013.02.08 |
---|---|
Application.OnTime 설명 (0) | 2012.12.28 |
벽에 부딪힌 vba (0) | 2012.08.13 |
How to solve the problem - "Compile Error: Can't find project or library" (0) | 2012.05.21 |
집중력의 한계 (0) | 2012.04.30 |