Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am using the following to find today's date in a column containing
dates for every day of the year. I have defined the serxh target using the Dim ThisDate declaration but when I run the code , for some unexpklained reason , I receive an error message saying that the object is not defined. Can you shed any light on this simple problem please? Dim ThisDate As Range Dim I As Range Dim Current As Range Sheets(2).Unprotect Set ThisDate = Range("B3") 'Cell contains today's date With ActiveSheet.Range("A:A") ' Searches for todays date in Column A Cells.Find(What:=ThisDate, _ After:=Cells(796), LookIn:=xlValues, _ LookAt:=xlPart, SearchOrder:=xlByColumns, SearchDirection:=xlNext, _ MatchCase:=False, SearchFormat:=False).Activate ActiveCell.Offset(0, 4).Select Set Current = Selection |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Using variables to make a date and using find method to find that. | Excel Programming | |||
Find method | Excel Programming | |||
Find Method | Excel Programming | |||
with -.find end with method | Excel Programming | |||
Find method | Excel Programming |