how to search the upper and lower of a range

  • Thread starter Thread starter leungkong
  • Start date Start date
L

leungkong

I want to search the upper and lower row of a range.
for example,
Range("B3:E10")
Upper = "B"
Lower = "E"

Thanks.
 
Well B & E are the first and last *columns* of the range. In code you could use:
Upper = Range("MyRange").Column
Lower = Upper + Range("MyRange").Columns.Count - 1
and something similar would also work with rows.
HTH
 
Back
Top