How to set range
For r = 2 to Cells(Rows.Count,"L").End(xlUp)Row
your code
Next r
--
HTH
RP
(remove nothere from the email address if mailing direct)
"Judy Ward" wrote in message
...
I want to loop through the range of cells that have data. I know how to
do
this with a "hard-coded" range:
Set r = Range("L2", "L50")
For n = 1 To r.Rows.coutn
<my code here
Next n
My problem is that I may have more (or less) than 50 rows. How can I set
r
equal to rows 2 through the last row with data (I don't want to perform
the
code on the first row).
Thank you for your help,
Judy
|