Day

From CometWiki

(Difference between revisions)
Jump to: navigation, search
m (minor)
(changed to numeric function)
Line 3: Line 3:
'''Syntax:'''  Day(CometDate)   
'''Syntax:'''  Day(CometDate)   
-
'''Discussion:'''  The CometDate Day function extracts the Day of the week from a CometDate Date Serial Number.  
+
'''Discussion:'''  The CometDate Day function extracts the Day of the month from a CometDate Date Serial Number.  
CometDates are based on a date of January 1, 1800. CometDates before that date are negative and after are positive.
CometDates are based on a date of January 1, 1800. CometDates before that date are negative and after are positive.
-
The Days extracted are:
+
The Days extracted are integers.
-
"Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"
+
-
 
+
-
This is a string function which yields the Full name of the Day in question. If you assign the result string to a 3 byte variable you may extract the 3 byte Day abbreviation.
+
The CometDate functions respect the rules for leap years (i.e., the years 1800 and 1900 were not leap years, but the year 2000 is a leap year).
The CometDate functions respect the rules for leap years (i.e., the years 1800 and 1900 were not leap years, but the year 2000 is a leap year).

Revision as of 17:43, 11 January 2011

Day Function -- Part of the CometDate series of functions.

Syntax: Day(CometDate)

Discussion: The CometDate Day function extracts the Day of the month from a CometDate Date Serial Number. CometDates are based on a date of January 1, 1800. CometDates before that date are negative and after are positive. The Days extracted are integers.

The CometDate functions respect the rules for leap years (i.e., the years 1800 and 1900 were not leap years, but the year 2000 is a leap year).

The practical range of CometDates is -657071 (01/01/01) to 2994623 (12/31/9999) but dates outside of that range may be usable in some contexts. There is no year 0 AD, The date goes from 1BC to 1AD.

For a reference of all of the functions associated with CometDates see this page CometDates.

Personal tools