AnsweredAssumed Answered

List of Dates Between Two dates

Question asked by dig on Nov 5, 2017
Latest reply on Nov 6, 2017 by Menno

Hi All - I am attempting to process that when a time sheet is created that 7 line records will also be created and then related to that time sheet, this is working.

 

I quickly discovered I would want to date of the line records to match the dates of that work week.

 

I have been to figure out how to determine the date of the most recent Sunday, what day number the current day is as well as other various information.

 

I am having trouble figuring out how I would go about getting a (list?) of the dates, of the 7 days starting from the Sunday ; to set to the line records especially if the time sheet is created mid week during a month change.

 

I have attempted to use this customer function https://www.briandunning.com/cf/8 with no success, either getting errors: Date range has exceeded the limit of X years. or Start date must be earlier than end date. I had tried the getasdate () suggestion in the comments, no luck

 

I am looking for guidance or a solution to learn from, please see attached file with my work so far.

 

Thank you

Outcomes