Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Selecting A Range
Dim rTable As Range
Dim WS As Worksheet Set WS = ActiveSheet Set rTable = WS.Cells.CurrentRegion Now you have rTable in memory referencing the sheet region. Don't forget that you can manipulate data easily without necessarily having the sheet active nor the cells selected. The code above works whatever sheet is active. Patrick Molloy Microsoft Excel MVP -----Original Message----- I am trying to write some code that will look at the uppermost cell in a range of cells, and then select the range of cells that belong to the same bunch of data (i.e. all the way to the right of the initial cell until the range ends, and all the way to the bottom of the initial cell until the range ends). Any help would be greatly appreciated. Thanks. Jason . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
selecting a range | Excel Discussion (Misc queries) | |||
Please help with selecting a range | Excel Discussion (Misc queries) | |||
Selecting range in list of range names depending on a cell informa | Excel Discussion (Misc queries) | |||
Selecting a Range | Excel Discussion (Misc queries) | |||
Selecting A Range | Excel Programming |