Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to find out the size of a variable-size array ?
Hi,
Is there a function to find out the size of a variable size array ? Thanks. regards, Adrian |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to find out the size of a variable-size array ?
UBound / LBound are what you're after.
If you want to know the number of dimensions: Check my website for "Number of Dimensions" (posted here for archive) Sub test() Dim arr(1, 2, 3, 4) As Long Dim i As Long On Error Resume Next Do: i = i - (LBound(arr, i + 1) * 0 = 0): Loop Until Err.Number On Error GoTo 0 MsgBox i End Sub -- Rob van Gelder - http://www.vangelder.co.nz/excel "Adrian" wrote in message ... Hi, Is there a function to find out the size of a variable size array ? Thanks. regards, Adrian |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Variable screen size, not resolution | Excel Worksheet Functions | |||
Variable size of chart | Charts and Charting in Excel | |||
Populating a summary of variable size. | Excel Discussion (Misc queries) | |||
Find size of array passed to user-defined function | Excel Programming | |||
Array Size | Excel Programming |