Last July?

AN60

Registered User.
Local time
Today, 10:52
Joined
Oct 25, 2003
Messages
283
I have tried using the following to give me the most recent 1st July;
=DateSerial(Year(Date())-1,7,1)

It works ok until I get to the 1st July in the present year then it gives me the 1st July for last year.

What will give me the most recent 1st July?
 
Try this:

=CDate("7/1/" & Year(Date())-IIf(Date()>=CDate("7/1/" & Year(Date())),0,1))
 
RichO
Thank you once again. When I tried it I had the 7th January but a quick reversal of the 1's & 7's and everything is working well. ;)
 

Users who are viewing this thread

Back
Top Bottom