View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default first and last row of range

Is the range a single area?

dim myRng as range
set myrng = activesheet.range("A9:g77") 'or something

with myrng
msgbox .row & vblf & .rows(.rows.count).row & vblf & .rows.count
end with

eugene wrote:

Hi,

Is there an easy way of capturing the first and last row of a range?

I can do it in a complicated way (assigning
ActiveWindow.RangeSelection.Address to a string variable and then parsing the
string variable to select the numbers within it which give me the first and
last row). But I suspect there exists a much simpler way to do it.

--
eugene


--

Dave Peterson