Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a complex calculation that I need to write in VBA which can be
represented with the following example. I need to iterate through all the cells in a noncontiguous range and starting from 1, put the number of the rows iterated through into the cells in that row so I end up with something like this: J K L T U 313 1 1 1 1 1 314 2 2 2 2 2 315 3 3 3 3 3 The problem is that the method for iterating through a noncontiguous range treats the cells as unrelated and hence I would have to iterate through the J313:L315 range and only then go on to the T313:U315 range, in which case I lose the count of the rows. (in the actual case, the values to be placed in the rows is much more difficult to re-compute then the row number). What I need to do, is iterate through row 313 (J-L, T-U), then row 314(same) then row 315(same). Is there an easier way to do this? thanks! |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Iteration | Excel Worksheet Functions | |||
"Print titles must be contiguos and complete rows or columns?" | Excel Discussion (Misc queries) | |||
Need help with iteration | Excel Discussion (Misc queries) | |||
Iteration | Excel Discussion (Misc queries) | |||
Iteration | Excel Discussion (Misc queries) |