Counting Rows in 2007

K

Ken Hudson

In many of my old macros I used the following code to get a row count in a
worksheet:

CountRows = Range("A65536").End(xlUp).Row

With the changes in 2007 I assume that I should use the following, more
generic code now?

CountRows = Cells(Rows.Count, "A").End(xlUp).Row
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top