macros to find a date value

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

Guest

How can I set up a macro (or button with a hyperlink) to quickly display a row with the current day's date in a spreadsheet which has a row for each day of the year. Or is there a better way then using buttons/macros etc.

I have tried to record a macro using the find command by pasting a cell content where the formula is =now() , but although this works for me before recording the macro, the macro doesn't seem to like something about the find command box.
 
Try this

Sub Today()
'Find date from today in a range
On Error GoTo a
Columns("a:a").Find(Date).Select
Exit Sub
a: MsgBox "nothing found"
End Sub


--
Regards Ron de Bruin
(Win XP Pro SP-1 XL2000-2003)




Bob said:
How can I set up a macro (or button with a hyperlink) to quickly display a row with the current day's date in a spreadsheet
which has a row for each day of the year. Or is there a better way then using buttons/macros etc.
I have tried to record a macro using the find command by pasting a cell content where the formula is =now() , but although
this works for me before recording the macro, the macro doesn't seem to like something about the find command box.
 
Back
Top