Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

Variable Date Selection

Status
Not open for further replies.

Verner

Mining
Jul 7, 2003
24
I am trying to setup a timesheet but don't want to rename the appropriate days of the week every week I start a new one. I simply want a template that adjusts the days of the week for the current week I am in.

What I want to do is have some sort of function that generates dates for the current week (some sort of a "Today() + X" where X is a variable function that fixes the dates for that given week).

Anybody know how?

Thanks
 
Replies continue below

Recommended for you

The day of the week for a given date never changes. Once you figure which date goes on the first day of the week, everything thing else is already known.

TTFN



 
I'm not clear on what you are trying to do, but:

=day(today()) will return a value from 0 to 6 corresponding to Sunday to Saturday, which would seem a good start.
 
Oops, sorry, it's

=WEEKDAY(TODAY()) returns 1 to 7

This litte formula:

=INT((NOW()-1)/7)*7+1

returns the previous Sunday. (Thanks to tek-tips)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor