MrExcel Publishing
Your One Stop for Excel Tips & Solutions

If Date = Expire then run macro


Posted by Jamie on December 05, 2001 5:16 PM

I have a column that has a date in it, I need that column to be checked and if the date is past the current date, then run a macro.

What Function would I use to make this work?

Thanks!


Posted by Paul on December 05, 2001 5:31 PM

Try this

Private Sub Workbook_Open()
If Sheets("Sheet1").Range("A1") < Now() Then
"your code here"
End If
End Sub