First day of the year

NOL

Registered User.
Local time
Today, 01:25
Joined
Jul 8, 2002
Messages
102
Hi ,


If i have an input date, is it possible to derive the first day of teh year from it ?

e.g INPUT START_DATE

1/3/2002 1/1/2002
2/6/1999 1/1/1999
4/16/2001 1/1/2001

I tried date value , but it gives me only for the current year.
e.g DateValue( "01-Jan") gives 1/1/2003

Any1 with ideas ? :D
Thanks in advance,
Gina.
 
The DateSerial() function will do it for you. Here's an example from the debug window:

start_date = #2/25/99#
firstDay = dateserial (year(start_date),1,1)
? firstday
1/1/99
 
Thanks so much !!
 

Users who are viewing this thread

Back
Top Bottom