EncodeDate

Top  Previous  Next

Prototype

 

floatOutput:= EncodeDate(intYear, intMonth, intDay)

 

Description

 

Converts the year, month and day value in a data value (float number).

 

Parameters

 

intYear: Integer corresponding to the Year value

intMonth: Integer corresponding to the month value

intDay: Integer corresponding to the day value

 

Returned value

 

floatOutput: float corresponding to the data value.

 

Notes

 

The returned value corresponds to the days passed from 1st Gennuary,1900.

 

Example

 

// It encodes year, month and day in a data

Data:=EncodeDate(2009,10,18)

 

// It controls the encoded data

if Data=Now then ShowMessage('Today is a great day !');