Variable Dimension Range/Double

G

guillaume

Hi There,

I have two main questions.
THANKS SO MUCH FOR YOUR HELP

1. I would like 1 to capture an array of data (a vector or
a matric) without using loops and 2 be able to manipulate
the data as a vector.
Is it possible ?? Range and Double have only one of the
two advantages mentioned above.
I would like to do
Dim temp(0 to 10) as ?????
temp()= range("A10:A19")
if temp(2)= 3 then ....

instead of
for i = 0 to 10
temp(i)= Range("A10").offset(i,0)
next i

2.I am having trouble to find the right dimension for the
code below. For the moment I cannot use variable as Temp
as I dont know which dimension to use.

With WorksheetFunction
Dim Temp as ???
Dim Cell as ???
Temp = .VLookup(Range("A2:C5"),Range("DT"), 2, 0)(.value?)
For Each Cell In Temp
If .IsError(Cell.Value) Then
MsgBox ("Error ")
Exit Sub
End If
Next Cell
End With
 
J

Jan De Messemaeker

Hi,

To question 1: never seen that in VBA
To question 2: this does not look like MS project, sorry.
HTH
 
J

John

Guillaume,
I recognize the code as VBA for Excel. Although I could probably figure
out a answer for you, why not try posting in the
Microsoft.public.excel.programming newsgroup.

John
Project MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top