Sub testVar()
'变量
Dim strT1 As String
strT1 = "A" '常量【加不加类型都可以】
Const strT2 As String = "B"
Const strT3 = "C" Dim i2 As Integer
i2 = Dim long4 As Long
long4 = '单浮点数
Dim s4 As Single
s4 = '双浮点数
Dim d8 As Double
d8 = '货币
Dim c8 As Currency
c8 =
End Sub
Sub testArr()
'一维数组【To定义,数定义】注意是圆括号!
Dim arr1( To ) As Double
arr1() = Dim arr1_2() As Double
arr1_2() = -
'二维数组【To定义,数定义】
Dim arr2( To , To ) As String
arr2(, ) = "二维数组" Dim arr2_2(, ) As String
arr2_2(, ) = "二维数组,简单定义"
MsgBox arr1_2()
End Sub