Home |
Search |
Today's Posts |
#9
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
The OP was asking (at least the way I read the question(!)) why I used:
Dim V as Variant instead of Dim V() as Long 'or variant or whatever. This explanation: This is because with the syntax shown, you are assigning an array directly to a dynamically declared array... the ability to do this was added in Version 6 of VB/VBA. seem to disagree with this earlier statement: The Array function requires it. That is because you can put almost anything in the argument list to the Array function, as long as you remember what is what, of course.<g For example... "Rick Rothstein (MVP - VB)" wrote: <<snipped But my real point to the OP was that some versions allow this syntax: dim V() as variant v = array(1,2,"A") and some versions don't allow it. This is because with the syntax shown, you are assigning an array directly to a dynamically declared array... the ability to do this was added in Version 6 of VB/VBA. Rick -- Dave Peterson |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How would I attach or assign values to a trendline? | Excel Worksheet Functions | |||
Assign Cell Values without a Loop | Excel Discussion (Misc queries) | |||
Array: Counting multiple values within array | Excel Worksheet Functions | |||
Assign values to text | Excel Worksheet Functions | |||
In Excel how can I assign values to a Yes or No question with IF | Excel Discussion (Misc queries) |