Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
refer cell using c
The following code where each cell in the the range is referred
for each c in Range("......") ------- -------- next c after exiting from for loop i want it to refer immediate next cell. how can it be possibl -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
refer cell using c
Before loop:
Set Orig = ActiveCell After loop: Orig.Offset(1).Select "anupam " wrote: The following code where each cell in the the range is referred for each c in Range("......") ------- -------- next c after exiting from for loop i want it to refer immediate next cell. how can it be possible --- Message posted from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
refer cell using c
anupam < wrote:
The following code where each cell in the the range is referred for each c in Range("......") ------- -------- next c after exiting from for loop i want it to refer immediate next cell. how can it be possible --- Message posted from http://www.ExcelForum.com/ Immediate next cell after what cell??? Bob Umlas provided code to refer to the next cell *down* from the cell that was active immediately prior to the loop. If you meant the next cell to the *right* of the cell that was active immediately prior to the loop, then you could use Orig.Offset(0,1) If you meant the next cell after the last cell in the range through which the code loops, you could use Set rng = Range("......")(Range("......").Count + 1) or Set rng = Range("......")(Range("......").Rows.Count, _ Range("......").Columns.Count + 1) depending on what you meant by "the next cell". Alan Beban |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to refer to a range except one cell | Excel Discussion (Misc queries) | |||
refer to last cell in worksheet? | Excel Worksheet Functions | |||
How make hyperlink refer to cell content rather than cell address. | Excel Discussion (Misc queries) | |||
How to refer to every 5 th cell? | Excel Discussion (Misc queries) | |||
How do I refer a Range to a Cell | Excel Worksheet Functions |