Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The direct answer to your question is No.
You can do this, which is sort of close in a way, kind of but not really. Sub Main() Const s As String = "1,2,3,4,5" Dim v As Variant, i As Integer v = Split(s, ",") For i = LBound(v) To UBound(v) Debug.Print v(i) Next i End Sub "Sam" wrote in message ... Is there a way to defind an array of constants in VBA? I tried the following and it would not compile. Const a(1) As Double = 1 Const a(2) As Double = 2 Thanks, Sam |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Vlookup - need the array to be constant | Excel Worksheet Functions | |||
Array Constant? | Excel Discussion (Misc queries) | |||
Array formula with a constant? | Excel Worksheet Functions | |||
array formula with constant | Excel Worksheet Functions | |||
Array constant issue | Excel Worksheet Functions |