Using date functions to automatically advance the date on a form

  • Thread starter Thread starter Jch461
  • Start date Start date
J

Jch461

I am trying to use a date function with arguements to assign a specific day
to a form. For example, using the =date() function on the form would put in
todays date. I need to know what arguements I would have to put in to
advance the date to a certian day... say like next sunday. The function
should allow the form to be printed with next sunday's date on it no matter
what day it it printed on. Say I printed the form today... it would have
next sunday's date already on it. Also I would like it to advance to the
next sunday as soon as next monday arrives. Thanks in advance! I used to
know how to do this but i simply cannot remember.
 
This expression will return the Sunday of the week the date is in. For
Sunday, it will return the current date, for every other day, it returns the
next Sunday date:

dateadd("d",choose(datepart("w",date),0,6,5,4,3,2,1),date)
 
Back
Top