# Calculate start date back from del. date

This topic is 6179 days old. Please don't post here. Open a new topic instead.

## Recommended Posts

Hi

I would like to know if anyone has a simple calculation to work out a start date back from a delivery date required, based upon the number of working days a project would take e.g.

If delivery date must be 31st Aug 2007 and it would take 12 working days to produce the project, then result = it must be started by 16th Aug 2007.

Any help would be much appreciated.

Thanks

Gill :-)

##### Share on other sites

check this one

http://www.briandunning.com/cf/722

shipByDate ( startDate ; numberOfDays ; satuday)

```
//name: shipByDate

//purpose: returns the day you need to ship by in order for your package to arrive by the date provided

//params:

//startDate: (the initial date)

//numberOfDays: (how many WORKING days after the start date)

//saturday: if saturday = "y" then saturday IS a working day, otherwise not.

Let(v=If(saturday="y"; "2,3,4,5,6,7";"2,3,4,5,6")

;

If(Filter ( DayOfWeek(startDate-1) ; v );

If(numberOfDays -1=0;startDate-1;

shipByDate(startDate-1;numberOfDays-1;saturday));

shipByDate(startDate-1;numberOfDays;saturday

)

))

```

##### Share on other sites

That's brilliant, thank you for your help!

##### Share on other sites

This topic is 6179 days old. Please don't post here. Open a new topic instead.

## Create an account

Register a new account