Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I'm using a For next loop to determine the number of rows and columns m
code should run in. What If I have multiple ranges of columns that need to be ru indepenedently. Let's say A:K then L:R then S:Z with the rows at constant of 1 to 100 For Each Cell in Range ("A:K") ??How do I state the next range? Does there need to be a Loop at the bottom of the code? Thanks:confused -- Message posted from http://www.ExcelForum.com |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I don't understand what you're doing but this is how you would get one For
loop to operate on those 3 ranges. Do something like this: Dim i as Range Set TheWholeRng=Union(Range("A1:K100"),Range ("L1:R100"),Range("S1:Z100")) For Each i In TheWholeRng 'What you want to do with each cell Next i "hotherps " wrote in message ... I'm using a For next loop to determine the number of rows and columns my code should run in. What If I have multiple ranges of columns that need to be run indepenedently. Let's say A:K then L:R then S:Z with the rows at a constant of 1 to 100 For Each Cell in Range ("A:K") ??How do I state the next range? Does there need to be a Loop at the bottom of the code? Thanks ![]() --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
loop over columns | Excel Discussion (Misc queries) | |||
Loop through ranges | Excel Programming | |||
How to loop through all ranges in a worksheet | Excel Programming | |||
loop to name ranges | Excel Programming | |||
How do I delete rows and columns in With With End Loop? | Excel Programming |