Thread: Array questions
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Edwin Tam (MS MVP) Edwin Tam (MS MVP) is offline
external usenet poster
 
Posts: 48
Default Array questions

1) No, you cannot do that
2) Using a loop is the normal way to do that, and it's the most efficient and easy to debug
3) I don't know a way to do that in the case you described


----- Tom wrote: ----

H

Working with arrays i a lot faster than worksheet functions (I suppos
so...). I have a few questions about arrays

1st questio
Is it possible to assign a value to multiple elements of an array: I'd lik
to do something like that

a(1 to 10) =

2nd question
Is it possible to get this faster, without loops

For i = 1 To UBound(a
If a(i) = strValue The
Matches = aMatches +
End I
Next

3rd question
Is it possible to use worksheets functions with arrays, something like that

matches = Application.CountIf("abc", aValues, 0


Maybe there is a tuturial available how to work with arrays most efficient

To