EncodeDateDay returns a TDateTime that represents a specified day ADayOfYear, in a specified year AYear.
The time portion of the return value is 00:00:00 - midnight at the start of the specified day ADayOfYear.
The definitions for AWeekOfYear and ADayOfWeek follow the ISO 8601 standard.
AYear is the year which can be any value from 1 through 9999 inclusive.
ADayOfYear is the day of the year, where 1st January is day 1, 2nd January is day 2, 1st February is day 32 e.t.c.
If AYear is not within range, ADayOfYear is less than 1 or greater than the number of days in AYear, EncodeDateDay will raise an error.
Declaration: function EncodeDateDay(const AYear, ADayOfYear: Word): TDateTime;