Sitemap Sitemap  |  Contact Us Contact Us  |  Clients Clients
   GetDayCount
  Home |  WebHare Lite |  Downloads |  HareScript |  Websites/CMS |  Applications
Search for:  in: 
HareScript
General functions
 
Base functions
Cryptography APIs
Date and time manipulation
Developers support
Mathematic and floating point utility functions
Money type utility functions
GetDayCount
  Returns the number of days since 01-01-0001.
 
Library wh::datetime.whlib
 
Syntax PUBLIC INTEGER FUNCTION GetDayCount (DATETIME date)
 
Description GetDayCount() returns the number of days that have passed since 01-01-0001 until date, /> starting at 1 for 01-01-0001. The function cannot return a negative value.

This function is in essence the same as MakeDayCount(), except that GetDayCount() uses a parameter of
type DateTime, whereas MakeDayCount() uses three integers for year, month and day.
 
Parameters
date The end date
 
Returns The number of days that have passed since 01-01-0001 until date. Value 1 represents 01-01-0001.
 
Example
// Returns the number of days passed since 01-01-0001 until today
INTEGER NumberOfDays := GetDayCount(GetCurrentDateTime());
 
In library 'datetime'
AddDaysToDate
AddMonthsToDate
AddTimeToDate
FormatDateTime
GetCurrentDateTime
GetDatetimeDifference
GetDayCount
GetLanguageDatetimeStrings
GetMonthLength
GetMsecondCount
GetMsecsDifference
GetYearLength
LocalToUTC
MakeDate
MakeDateFromDayCount
MakeDateFromParts
MakeDateFromText
MakeDateTime
MakeDayCount
MakeTime
UnpackDateTime
UTCtoLocal
 
Top To top of page