dynamic date array
Posted on 2006-05-29
I need to create a dynamic date array based on two date field and an interval number field.
I have date1 and date2 on doc
I have interval number field
on saving the document, I want my script to create an array of date ranges between date1 and date2 taking the interval value into consideration and save all those values to a field in a document
So if date1 is today and date2 is one year away and the interval is 30 days, the array should have the following dates:
and so on until the end which is 31/07/2007 is reached
Then save all those values to a multi value date field on the document.
Thank you in advance.