Date :: toDays - Convert date to number of days
The function converts the date to the number of days passed since 1.1.1870.
Return value: Set date from days ( int32 )
The function calculates the date from the number of days passed in iDayNum. The value must be greater than 0.