Row number of last cell with data

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

Guest

Hi all.

I'm trying to find the code for obtaining the row number of the last cell
with data in a spreadsheet. This is probably an easy one. I don't see any
posts jumping out at me about it though.
 
Sub Test()
lRow = ActiveSheet.Cells(Rows.Count, 1).End(xlUp).Row
MsgBox lRow
End Sub
 

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

Back
Top