Gary Samuels
asked on
Working with dates
Private Sub btnAugust_Click()
Debug.Print Date
If Date < "8/1/" & (Year(Date)) Then
Debug.Print ("date is less that 8/1/" & (Year(Date)))
Else
Debug.Print ("date is greater that 8/1/" & (Year(Date)))
End If
Results:
9/13/2013
date is less that 8/1/2013
Why is 9/13/2013 less that 8/1/2013?
Debug.Print Date
If Date < "8/1/" & (Year(Date)) Then
Debug.Print ("date is less that 8/1/" & (Year(Date)))
Else
Debug.Print ("date is greater that 8/1/" & (Year(Date)))
End If
Results:
9/13/2013
date is less that 8/1/2013
Why is 9/13/2013 less that 8/1/2013?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.