Go to record end, then one across

M

Munchkin

I want my macro to select J7, go to the record end, then go across to the
next cell, which is empty. As you can see when I recorded my macro it
referenced a specific cell instead (K751). Hope I explained clearly - thanks
in advance for help.

Range("J7").Select
Selection.End(xlDown).Select
Range("K751").Select
 
J

Jacob Skaria

Try this

Range("J7").End(xlDown).Offset(1).Select

OR if you have blank cells in between try the below.....

Cells(Rows.Count, "J").End(xlUp).Offset(1).Select
 
R

Rick Rothstein

If I understand your question correctly, this should do what you want...

Cells(Range("J7").End(xlDown).Row, Columns.Count).End(xlToLeft).Offset(,
1).Select
 
R

Rick Rothstein

That code line should have all been on one line.

Cells(Range("J7").End(xlDown).Row, Columns.Count).End(xlToLeft).Offset(,
1).Select
 

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