Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Array Ubound
Hi all, I have filled a 2d array with values - can i find out the size of the array WHERE Arry(1, i) = 'WB01' - for example. TIA -- gti_jobert ------------------------------------------------------------------------ gti_jobert's Profile: http://www.excelforum.com/member.php...o&userid=30634 View this thread: http://www.excelforum.com/showthread...hreadid=526695 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Array Ubound
Are you asking how to count the number of occurances where the array contains "WB01" regards -- tony h ------------------------------------------------------------------------ tony h's Profile: http://www.excelforum.com/member.php...o&userid=21074 View this thread: http://www.excelforum.com/showthread...hreadid=526695 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Array Ubound
yes i am, suppose I would just loop through the entire array and set up a count where array = 'WB01' - thought I might just be able to use ubound with a criteria set on it? -- gti_jobert ------------------------------------------------------------------------ gti_jobert's Profile: http://www.excelforum.com/member.php...o&userid=30634 View this thread: http://www.excelforum.com/showthread...hreadid=526695 |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Array Ubound
UBound(Arry,1)
and UBound(Arry,2) for the two dimensions of the array -- HTH Bob Phillips (remove nothere from email address if mailing direct) "gti_jobert" wrote in message ... Hi all, I have filled a 2d array with values - can i find out the size of the array WHERE Arry(1, i) = 'WB01' - for example. TIA -- gti_jobert ------------------------------------------------------------------------ gti_jobert's Profile: http://www.excelforum.com/member.php...o&userid=30634 View this thread: http://www.excelforum.com/showthread...hreadid=526695 |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Array Ubound
You could drop it onto a spreadsheet and count those
Range("M1:N10") = arry MsgBox Application.CountIf(Range("M1:N10"), "WB01") -- HTH Bob Phillips (remove nothere from email address if mailing direct) "gti_jobert" wrote in message ... yes i am, suppose I would just loop through the entire array and set up a count where array = 'WB01' - thought I might just be able to use ubound with a criteria set on it? -- gti_jobert ------------------------------------------------------------------------ gti_jobert's Profile: http://www.excelforum.com/member.php...o&userid=30634 View this thread: http://www.excelforum.com/showthread...hreadid=526695 |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Array Ubound
UBound provides the current upper bound of the specified dimension of the
array. I suspect there is nothing faster than looping through the array. Set it up as a function that accepts the array and the target string as arguments and you will have a reusable routine. -- Regards, Tushar Mehta www.tushar-mehta.com Excel, PowerPoint, and VBA add-ins, tutorials Custom MS Office productivity solutions In article , says... yes i am, suppose I would just loop through the entire array and set up a count where array = 'WB01' - thought I might just be able to use ubound with a criteria set on it? -- gti_jobert ------------------------------------------------------------------------ gti_jobert's Profile: http://www.excelforum.com/member.php...o&userid=30634 View this thread: http://www.excelforum.com/showthread...hreadid=526695 |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Array Ubound
If the functions in the freely downloadable file at
http://home.pacbell.net/beban are available to your workbook ArrayCountIf(Arry,"WB01") will return the number of occurrences. Alan Beban gti_jobert wrote: yes i am, suppose I would just loop through the entire array and set up a count where array = 'WB01' - thought I might just be able to use ubound with a criteria set on it? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Why is this returning a Ubound value of zero | Excel Discussion (Misc queries) | |||
UBound of multi-dimensional array? | Excel Programming | |||
Handling ubound on an uninitialised array | Excel Programming | |||
Ubound & Lbound | Excel Programming |