S
Steve
Sub Find_Todays_Date()
Dim FindString As Date
Dim Rng As Range
FindString = CLng(Date)
With Sheets("Sheet1").Range("A:A")
Set Rng = .Find(What:=FindString, _
After:=.Cells(.Cells.Count), _
LookIn:=xlFormulas, _
LookAt:=xlWhole, _
SearchOrder:=xlByRows, _
SearchDirection:=xlNext, _
MatchCase:=False)
If Not Rng Is Nothing Then
Application.Goto Rng, True
Else
MsgBox "Nothing found"
End If
End With
End Sub
This is my code. It is supposed to goto the date when executed. It works
fine on my machine, but I tried putting it on someone else's and it gave me a
data error message. It said something like the subprocedure is out of range.
It was Data Error 9. I've checked the refrence style setting in the options
pannel and they are the same on both machines. We are both using MS 2003, but
come to think of it Im not sure which SP the other one is using... Any ideas?
Dim FindString As Date
Dim Rng As Range
FindString = CLng(Date)
With Sheets("Sheet1").Range("A:A")
Set Rng = .Find(What:=FindString, _
After:=.Cells(.Cells.Count), _
LookIn:=xlFormulas, _
LookAt:=xlWhole, _
SearchOrder:=xlByRows, _
SearchDirection:=xlNext, _
MatchCase:=False)
If Not Rng Is Nothing Then
Application.Goto Rng, True
Else
MsgBox "Nothing found"
End If
End With
End Sub
This is my code. It is supposed to goto the date when executed. It works
fine on my machine, but I tried putting it on someone else's and it gave me a
data error message. It said something like the subprocedure is out of range.
It was Data Error 9. I've checked the refrence style setting in the options
pannel and they are the same on both machines. We are both using MS 2003, but
come to think of it Im not sure which SP the other one is using... Any ideas?