Scroll to last cell with date

sharky12345

Well-known Member
Joined
Aug 5, 2010
Messages
3,404
Office Version
  1. 2016
Platform
  1. Windows
I have a series of dates in column E and I need to scroll to the last cell which has today as the current date.

If it makes a difference, the cells are formatted as "dd/mm/yyyy"

Anyone?
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
Maybe...

Code:
Sub findlastdate()
Application.Goto Columns(5).Find(CDate(Date), , xlValues, , xlByRows, xlPrevious), True
End Sub
 
Last edited:
Upvote 0
Cheers Mark - however, that gives me a run time error 5, Invalid procedure call or argument......

Any ideas?
 
Upvote 0
Try this:
Since you say Todays Date is in last cell with data in column E.
Code:
Sub Goto_Today()
'Modified 10/9/2019 4:02:05 AM  EDT
Application.ScreenUpdating = False
Dim i As Long
Dim j As Long
Dim Lastrow As Long
Lastrow = Cells(Rows.Count, "E").End(xlUp).Row
Application.Goto Reference:=Range("E" & Lastrow), Scroll:=True
        With ActiveWindow
            i = .VisibleRange.Rows.Count / 2
            j = .VisibleRange.Columns.Count / 2
            .SmallScroll Up:=i, ToLeft:=j
        End With
Application.ScreenUpdating = True
End Sub
 
Upvote 0
Cheers Mark - however, that gives me a run time error 5, Invalid procedure call or argument......

Any ideas?

No error when I run it so no unless you are using a Mac.

Since you say Todays Date is in last cell with data in column E
M.A.I.T, that isn't what the question says.
 
Last edited:
Upvote 0
Thanks - got it working, not sure what I'd done but it works fine now.

Thanks to both for your help!
 
Upvote 0

Forum statistics

Threads
1,213,536
Messages
6,114,208
Members
448,554
Latest member
Gleisner2

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top