Difference between revisions of "ELDateToDateTime"

From MultiCharts
Jump to navigation Jump to search
 
(3 intermediate revisions by 3 users not shown)
Line 3: Line 3:
 
EL Date is specified in the YYYMMdd format, where YYY is the number of years since 1900, MM is the month, and dd is the day of the month.  
 
EL Date is specified in the YYYMMdd format, where YYY is the number of years since 1900, MM is the month, and dd is the day of the month.  
  
The integer portion of the DateTime value indicates the number of days that have elapsed since January 1st, 1900, and the fractional portion of the DateTime value indicates the fraction of the day that has passed since midnight.  
+
The integer portion of the DateTime value indicates the number of days that have elapsed since December 30th, 1899, and the fractional portion of the DateTime value indicates the fraction of the day that has passed since midnight.  
 
   
 
   
 
==== Usage ====
 
==== Usage ====
Line 11: Line 11:
 
   
 
   
 
==== Example ====
 
==== Example ====
<syntaxhighlight>ELDateToDateTime(1080101)  will return a value of 39448.00000000,  
+
<syntaxhighlight>ELDateToDateTime(1080101)  will return a value of 39448.00000000, corresponding to the specified  
corresponding to the specified date of January 1st, 2008  
+
date of January 1st, 2008  
  
ELDateToDateTime(990402)  will return a value of 36252.00000000,  
+
ELDateToDateTime(990402)  will return a value of 36252.00000000, corresponding to the specified  
corresponding to the specified date of April 2nd, 1999</syntaxhighlight>  
+
date of April 2nd, 1999</syntaxhighlight>  
  
  

Latest revision as of 13:37, 15 February 2023

Returns the integer portion of a double-precision decimal DateTime value corresponding to the specified EL Date.

EL Date is specified in the YYYMMdd format, where YYY is the number of years since 1900, MM is the month, and dd is the day of the month.

The integer portion of the DateTime value indicates the number of days that have elapsed since December 30th, 1899, and the fractional portion of the DateTime value indicates the fraction of the day that has passed since midnight.

Usage

ELDateToDateTime(YYYMMdd)

Where: YYYMMdd - a numerical expression, specifying the date in EL YYYMMdd format

Example

ELDateToDateTime(1080101)  will return a value of 39448.00000000, corresponding to the specified 
date of January 1st, 2008 

ELDateToDateTime(990402)  will return a value of 36252.00000000, corresponding to the specified 
date of April 2nd, 1999