one_more_cave_dweller
Board Regular
- Joined
- Sep 27, 2004
- Messages
- 118
I would like to trigger a macro if cell a1=the last day of any month. How could I write the code?
Thanks ray:
Thanks ray:
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Intersect(Target, [a1]) Is Nothing Then Exit Sub
If Day([a1]) = Day(DateSerial(Year([a1]), Month([a1]) + 1, 0)) Then Macro
End Sub