Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Referencing specific cells in an array of ranges
I have declared
Public AllRanges(1 To 10) As Range and assigned various ranges to each of the 10 array elements. Then I use other analyses to identify two "cells" of interest. I'm having trouble with properly referring to individual cells within the array of ranges. For example, I would expect something like the following to give me the value of the first cell in the first range: Debug.print AllRanges(1)(1,1) or maybe Debug.print AllRanges(1)(1,1).value Since my ranges are all single columns, I also tried to reference this as a 1-D array Debug.print AllRanges(1)(1) and Debug.print AllRanges(1)(1).value but still no luck. Can anyone help me with the syntax of how to properly reference a single cell's value within an array of ranges? Many thanks, Keith |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Referencing specific cells in an array of ranges
This is now working- apologies for the extra bandwidth.
"ker_01" wrote: I have declared Public AllRanges(1 To 10) As Range and assigned various ranges to each of the 10 array elements. Then I use other analyses to identify two "cells" of interest. I'm having trouble with properly referring to individual cells within the array of ranges. For example, I would expect something like the following to give me the value of the first cell in the first range: Debug.print AllRanges(1)(1,1) or maybe Debug.print AllRanges(1)(1,1).value Since my ranges are all single columns, I also tried to reference this as a 1-D array Debug.print AllRanges(1)(1) and Debug.print AllRanges(1)(1).value but still no luck. Can anyone help me with the syntax of how to properly reference a single cell's value within an array of ranges? Many thanks, Keith |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Array formula: how to join 2 ranges together to form one array? | Excel Worksheet Functions | |||
Return a cell value based on specific combinations of cells in an array | Excel Worksheet Functions | |||
Referencing cells that array covers | Excel Programming | |||
Referencing cells text output if it meets specific conditions | Excel Worksheet Functions | |||
variant array containing cel adresses convert to actual ranges-array | Excel Programming |