I need to print membership cards which show
"Valid to June (Next Year)" always.
I have adapted some earlier advice to build both of these options
which work but seem clumsy.
="Valid to June " & DatePart("yyyy",Date()+365)
="Valid to June " &
Year(Date())+(Date()<DateSerial(Year(Date()),7,2))+1
Is there an easier piece of code?
Thanks,
Robin Chapple
Ken Snell [MVP] - 30 Jul 2005 02:33 GMT
Easier? I leave that to you as a conclusion:
="Valid to June " & Year(Date()) - (Date() > DateSerial(Year(Date(), 7, 0))
or
="Valid to June " & Year(Date()) - (Month(Date()) > 6)

Signature
Ken Snell
<MS ACCESS MVP>
>I need to print membership cards which show
>
[quoted text clipped - 13 lines]
>
> Robin Chapple
Tom Lake - 30 Jul 2005 07:00 GMT
>I need to print membership cards which show
>
[quoted text clipped - 9 lines]
>
> Is there an easier piece of code?
Does this do it for you?
= "Valid to June " & Year(Date()) + 1
Tom Lake
prairiewind - 19 Sep 2008 02:37 GMT
The header of my report has the current and next year both on it (i.e. 2008-
2009). I've been manually updating the last couple of years and thanks to
your help, I don't have to do it any more. Code reads: =Year(Date()) & " - "
& Year(Date())+1 in case anyone else needs it.
>>I need to print membership cards which show
>>
[quoted text clipped - 7 lines]
>
>Tom Lake