lastrow = Sheets("User Interface").Cells(Rows.Count, "AB19").End(xlUp).row
I'm trying to find the last used row of a column starting at a specific cell, AB19. But there is an error. I'm still new to VBA so help is appreciated.
lastrow = Sheets("User Interface").Cells(Rows.Count, "AB19").End(xlUp).row
I'm trying to find the last used row of a column starting at a specific cell, AB19. But there is an error. I'm still new to VBA so help is appreciated.
The second factor of Cells is column, so you just put column reference there, i.e. "AB" instead of "AB19":
lastrow = Sheets("User Interface").Cells(Rows.Count, "AB").End(xlUp).row
I did try and this worked.