Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default double array

I have to process 4-7 sheets with similar columns. WHat i
have to do is I have to search for the column
heading "GF", "Total" in all the sheets (all sheets are
exactly similar). Ihave to also search for last rows in
all the sheets. THis is simple as i can create array of
variables. Like i can store lastrow(1)...of sheetone and
likewise.

But the confusing part is when i have to trap a series of
values in an array in each sheet. Here i feel i need to
create double arrays. Like if i am on sheet 1 then
something like trapCelValue(sht1,counter1)
so sht1 will be the variable which stores sheet
numbers.... and counter1 will be the counter for storing
hte values.
like in sheet1 i will have to store values like : 13, 18,
45, 22, 90
so my array should be

trapCelValue(1,1)="13"
trapCelValue(1,2)="18"
trapCelValue(1,3)="45"
trapCelValue(1,4)="22"
trapCelValue(1,5)="90"

i am slightly confused as to how to declare and process...
any simple example will be helpful

thanks a lot

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,080
Default double array

Just declare a 2D array:

Dim trapCelValue(1 To 5, 1 To 10) As String

You seem to be treating the numbers as text as you have enclosed them in
quotes. Or you could remove the quotes and declare trapCelValue as a numeric
data type.

Substitute the actual upper bounds for 5 and 10.
--

Vasant



wrote in message
...
I have to process 4-7 sheets with similar columns. WHat i
have to do is I have to search for the column
heading "GF", "Total" in all the sheets (all sheets are
exactly similar). Ihave to also search for last rows in
all the sheets. THis is simple as i can create array of
variables. Like i can store lastrow(1)...of sheetone and
likewise.

But the confusing part is when i have to trap a series of
values in an array in each sheet. Here i feel i need to
create double arrays. Like if i am on sheet 1 then
something like trapCelValue(sht1,counter1)
so sht1 will be the variable which stores sheet
numbers.... and counter1 will be the counter for storing
hte values.
like in sheet1 i will have to store values like : 13, 18,
45, 22, 90
so my array should be

trapCelValue(1,1)="13"
trapCelValue(1,2)="18"
trapCelValue(1,3)="45"
trapCelValue(1,4)="22"
trapCelValue(1,5)="90"

i am slightly confused as to how to declare and process...
any simple example will be helpful

thanks a lot



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Complex conditional summing - array COUNT works, array SUM gives#VALUE fatcatfan Excel Worksheet Functions 4 November 18th 09 06:41 PM
Prevent cell/array references from changing when altering/moving thecell/array nme Excel Discussion (Misc queries) 1 September 19th 08 01:53 PM
Is it poss to have a double array in Excel 2003? Beads Excel Worksheet Functions 2 March 30th 07 03:46 PM
double axis, double problem (i hope only to me) kitcho Charts and Charting in Excel 1 December 30th 06 12:52 AM
meaning of : IF(Switch; Average(array A, array B); array A) DXAT Excel Worksheet Functions 1 October 24th 06 06:11 PM


All times are GMT +1. The time now is 01:32 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"