Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Data in variable row numbers...
I use the following to find a header located in a row of cells. EndCol var
depends on the dataset size and Sub Call_Data operates on the data below the header (in columns). This is repeated for Val2, Val3 etc.. Col = 1 For i = StrtCol To EndCol If ActiveCell = Val1 Then Call Get_Data Else ActiveCell.Offset(0, Col).Select End If Next i The issue is that data is arranged in blocks, such that the next line of headers+data is in a row below the last block of data (varies with the dataset size). I therefore need: - look for header in row, return data OR - find next header row(done this), change row, look for header, return data Repeat for other rows of headers Repeat for Val2 etc... Nested If, Else procedure probably should do it though can't get one to work. Maybe faster if the macro can look for all Vals (1,2,3) in one row of headers and then move on, though this is way beyond me at present... Any resources, ideas would be great.. M. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Divide variable numbers into groups | Excel Discussion (Misc queries) | |||
Adding variable range of numbers | Excel Worksheet Functions | |||
Average the last eight or nine (Variable) numbers in a row. | Excel Discussion (Misc queries) | |||
extracting numbers from variable text | Excel Discussion (Misc queries) | |||
VBA Cell row-column numbers to variable | Excel Programming |