Setting a range that varies

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to create a chart from a range that has dates in Column a
(starting at Row 5) and share value in Column B
THis works
Range("A5:B7").Select
but what I can't find how to do is how to set it from A5 to the last cell
with data in column B rather than B7 because as I add data I want the chart
to update.

I am sure it is very simple.
Any clues please
Stephen
 
cLastRow = Cells(Rows.Count,"B").End(xlUp).Row
Range("A5:B" & cLastRwo).Select

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
Bob Phillips said:
cLastRow = Cells(Rows.Count,"B").End(xlUp).Row
Range("A5:B" & cLastRwo).Select
Thanks for this. It helped me solve a problem that has been bugging me for 2
days.
 
Back
Top