Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I'm creating a timesheet database a

Status
Not open for further replies.

Samulayo

Programmer
Aug 13, 2002
46
GB
I'm creating a timesheet database and the entry of a new timesheet requires the date and week number that the timesheet corresponds to. I know how to find the week for the current date using
=Format(Now(),"ww")
in the default value of a field, but i would like the week number for the date entered to be the control for this value instead. i.e. something along the lines of
=Format([date],"ww")
where [date] is the field 'date' on the table (btw that does not work as life's not so simple.)
and help with this would be greatly appreciated.

Regards

Samulayo
 
Have a look at thread702-558714
hth

regards jon92
 
It works...but the date should be passed in US format ("mm/dd/yyyy") or in a format that cannot be mistaken: "dd-mmm-yyyy"

I always use the latter - a preference of mine

Try:
Format(Format([YourDate], "dd-mmm-yyyy"), "ww")


HTH


[pipe]
Daniel Vlas
Systems Consultant

 
Thanks alot, i've got it working now.

Regards
Samulayo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top