Excel - Select Row Below Active Region

DHompster
DHompster used Ask the Experts™
on
How do I find and select a cell in the first row below the currently active area; the next empty row?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Top Expert 2010

Commented:
Hello DHompster,

Please clarify what you mean.  It is easy to grab the first row under the ActiveCell's CurrentRegion, but that it is
*not* necessarily the same thing as "the next empty row".

Regards,

Patrick

Author

Commented:
Thanks, Patrick,

Sorry for the ambiguity.  I guess it's the next empty row that I'm looking for.

Example:  The block of data is currently in A10:F12.

I need to end up with B13 selected.


Top Expert 2010
Commented:
DHompster,

Something like this:


Sub SelectNextRow()

    Cells(Rows.Count, "a").End(xlUp).Offset(1, 0).Resize(1, 6).Select

End Sub

Patrick

Author

Commented:
Boy, I'm bad and I'm sorry!  

Your solution was perfect, but I neglected to mention that there's stuff lower on the spreadsheet.

Let me attach the spreadsheet.  Specifically, I'm trying to copy B35:F35 up to the first blank line under the block of expenses.  In this case, B35:F35 would be copied to B13.

So far, I have this code, which selects all the records from A10:F12:

    Range("A10").Select    
    Set tbl = ActiveCell.CurrentRegion
    tbl.Offset(1, 0).Resize(tbl.Rows.Count - 1, _
    tbl.Columns.Count).Select


Just need to get to the line below the selected section.

THANKS!!


CASH-EXPENSE-REPORT-DAN-HOMP-02-.xls

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial