Date and Time
Structural Elements of a Program
 
In the service of the date and time functions the date and time are expressed as a numeric value representing the number of seconds from January 1, 1601 in 00:00:00, with a resolution accuracy given in milliseconds. This provides for easy executing the time operations, such as time addition and subtraction.
 
Image bm970.GIF actual date and time
 
The actual date and time element is a numeric variable representing the local actual date and time. The variable can be read and data can be recorded in it, thus changing the actual date and time.
 
Image bm971.GIF convert local time to world time
 
The convert local time to world time function converts the local time to the world time (UTC, Universal Time Coordinated). A precondition for a correct conversion is the setting of the time zone and the summer time switch in the Windows system (Control Panels / Date and Time / Time Zone).
 
Image bm972.GIF convert world time to local time
 
The convert world time to local time function converts the world time (UTC, Universal Time Coordinated) to the local time. A precondition for a correct conversion is the setting of the time zone and the summer time switch in the Windows system (Control Panels / Date and Time / Time Zone).
 
Image bm973.GIF merge components of date and time
Image bm974.GIF year (default 1601)
Image bm975.GIF month (default 1)
Image bm976.GIF day (default 1)
Image bm977.GIF hour (default 0)
Image bm978.GIF minute (default 0)
Image bm979.GIF second (default 0)
Image bm980.GIF millisecond (default 0)
 
The merge components of date and time function enables to convert the date and time represented by corresponding data to a representation in a certain number of seconds. It is possible to use only a part of the date and time indication as a date entry or as a time entry only. In this case it is possible to leave the default setting of the positions not used. Thus, for example, when using the time only the resulting reading will represent the number of seconds from the beginning of the day. The data may be processed by common operations, as, for instance the representation by means of a function for the time conversion to a text form.
 
Image bm981.GIF year from date and time
 
The year from date and time function takes the year entry from the date and time and returns it as a numeric data.
 
Image bm982.GIF month from date and time
 
The month from date and time function takes the month entry from the date and time and returns it as a numeric data.
 
Image bm983.GIF day from date and time
 
The day from date and time function takes the day entry from the date and time and returns it as a numeric data.
 
Image bm984.GIF day of week from date and time (0=sunday, 1=monday, ...)
 
The day of week from day and time function takes the day-of-the-week entry from the date and time and returns it as a numeric data. Number 0 represents Sunday, number 1 Monday through number 6 representing Saturday.
 
Image bm985.GIF hour from date and time
 
The hour from date and time function takes the hour entry from the date and time and returns it as a numeric data.
 
Image bm986.GIF minute from date and time
 
The minute from date and time function takes the minute entry from the date and time and returns it as a numeric data.
 
Image bm987.GIF second from date and time
 
The second from date and time function takes the second entry from the date and time and returns it as a numeric data.
 
Image bm988.GIF millisecond from date and time
 
The millisecond from date and time function takes the millisecond entry from the date and time and returns it as a numeric data.
 
Image bm989.GIF convert date to text "day.month.year"
 
The convert date to text "day.month.year" function converts the date data to a date text in the European format "day.month.year".
 
Image bm990.GIF convert date to text "month/day/year"
 
The convert date to text "month/day/year" function converts the date data to a date text in the American format "month/day/year".
 
Image bm991.GIF convert date to text "year-month-day"
 
The convert date to text "year-month-day" function converts the date data to a date text in the Japanese format "year-month-day".
 
Image bm992.GIF convert time to text "hour:minute:second" (24 hours)
 
The convert time to text "hour:minute:second" (24 hours) function converts the time data to a time text with a 24-hour cycle.
 
Image bm993.GIF convert time to text "hour:minute:second x" (12 hours)
 
The convert time to text "hour:minute:second x" (12 hours) function converts the time data to a time text with a 12-hour cycle, supplemented by the "a" (=morning) or "p" (=afternoon) indicator.

Full Html Context Help of The Peter - Gemtree Software & Children Programming