Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Select a column from a matrix
Hello,
I have declared a variable: Dim dataHere(1 to 9, 1 to 3) as double How could I select the second column from this matrix to use in further calculations ? I tried dataHere(All, 2) and dataHere(1 To 9 , 2)but got an error each time. Any ideas ? Tom |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Select a column from a matrix
not exactly sure what you're trying to do, but maybe this will give you an idea.
Sub test2() Dim x As Long Dim dataHere As Variant dataHere = Range("A1:C9") For x = LBound(dataHere) To UBound(dataHere) Debug.Print dataHere(x, 2) Next End Sub -- Gary wrote in message ... Hello, I have declared a variable: Dim dataHere(1 to 9, 1 to 3) as double How could I select the second column from this matrix to use in further calculations ? I tried dataHere(All, 2) and dataHere(1 To 9 , 2)but got an error each time. Any ideas ? Tom |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Select a column from a matrix
On Jun 11, 4:02*pm, "Gary Keramidas" <GKeramidasATmsn.com wrote:
not exactly sure what you're trying to do, but maybe this will give you an idea. Sub test2() Dim x As Long Dim dataHere As Variant dataHere = Range("A1:C9") For x = LBound(dataHere) To UBound(dataHere) * * * Debug.Print dataHere(x, 2) Next End Sub -- Gary wrote in message ... Hello, I have declared a variable: Dim dataHere(1 to 9, 1 to 3) as double How could I select the second column from this matrix to use in further calculations ? I tried dataHere(All, 2) and dataHere(1 To 9 , 2)but got an error each time. Any ideas ? Tom- Hide quoted text - - Show quoted text - Hi Gary, I want to use the result in a MMULT function, so want to take out the second column and go: MMULT(dataHere(All, 2), anotherArray) I'm not sure if this can be done. Tom |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Column multiplied by a matrix | Excel Discussion (Misc queries) | |||
Making a Matrix into a column....... | Excel Discussion (Misc queries) | |||
Matrix to a Column Report | Excel Programming | |||
Changing a matrix into one large column | Excel Programming | |||
Matrix to single column | Excel Worksheet Functions |