Loading...
 

CX_TIME - Time

CX_TIME

Class hierarchy
Description:

This class is used to display a specific time. During generation, the current system time is adopted. A time is normally between 0.00 and 24.00 hours.

Display on screen

InstantView® Instruction: DigitalTime

In connection with this interface object and certain InstantView®instructions, the flags belonging to the object play an important role, as they can be used to modify the representation of the object.

Note: With the functions AddHundredthSecond, AddSecond, AddMinute and AddHour and the operators + and - it is possible to create clock times that can be after 24:00. This allows you to see whether the time of the result is on the same day (0:00 - 24:00) as the starting time, or in days after (times greater than 24:00)

Note: A digital clock is available as an InstantView® instruction DigitalTimer, and an analog clock is available as an InstantView® instruction AnalogTimer. Each of these two surface objects transmits the message MIDNIGHT at 0.00 o'clock. The following programme shows the use of the two surface objects:

Code example:

In dem Beispiel-Programm werden fünf Sekunden zu der Zeit "12:11.10:09" addiert, sodass sich die Uhrzeit zu "12:11.15:09" ändert. 

Var(time)
CreateTransObject(TIME) -> time
"12:11.10:09" time Put
5 time Call(AddSecond)

In dem Beispiel-Programm werden fünf Minuten zu der Zeit "12:11.10:09" addiert, sodass sich die Uhrzeit zu "12:16.10:09" ändert. 

Var(time)
CreateTransObject(TIME) -> time
"12:11.10:09" time Put
5 time Call(AddMinute)

In dem Beispiel-Programm werden fünf Stunden zu der Zeit "12:11.10:09" addiert, sodass sich die Uhrzeit zu "17:11.10:09" ändert. 

Var(time)
CreateTransObject(TIME) -> time
"12:11.10:09" time Put
5 time Call(AddHour)

List of methods (MDI)
Function MA* Parameters Return Brief description
AddHundredthSecond Hundredths of a second addition (see note)
AddSecond Second addition (see note)
AddMinute Minutes addition (see note)
AddHour Hour addition (see note)
DayTime STRING Time of day
Duration OBJECT Returning the duration
Encompassed (OBJECT) INTEGER "Contained in" test
EndOfPeriod OBJECT Calculate end time
ExportTimeNumber (INTEGER) STRING Export of the time as string
HourOfTime INTEGER Hourly share of time
HundredthSecondOfTime INTEGER hundredths of a second of time
ImportTimeNumber (STRING, INTEGER) Import of the time as string
JoinPeriods (OBJECT) VOLATILE_OBJECT combine two transferred time spans into one
MinuteOfTime INTEGER Percentage of time in minutes
MLDayTime MLSTRING Multilingual time of day
NextTerm (OBJECT) OBJECT the date within the date
Overlap (OBJECT) INTEGER Overlap test
OverlappingPeriod (OBJECT) VOLATILE_OBJECT calculate the intersection (disjunction) of two time spans
RealEndOfPeriod OBJECT calculate "real" end time
RealStartOfPeriod OBJECT calculate "real" start time
SecondOfTime INTEGER Second part of time
SetHour (INTEGER) Setting a new hour
SetHundredthSecond (INTEGER) Setting a new hundredth of a second
SetMinute (INTEGER) Setting a new minute
SetSecond (INTEGER) Setting a new second
SetTime
231532
STRING, INTEGER Import time from the passed string
SetZero
StartOfPeriod OBJECT Calculate start time
ValueInMinutes INTEGER Time in minutes
ValueInSeconds INTEGER Time in seconds
ValueOfTime INTEGER Time in hundredths of a second
string INTEGER CX_STRING Returns the string representation of the object

* MA = Member Access Function

Data Directory (DDI)
Data field Type Reference class I* Brief description
this CX_TIME The time of day

* I = Indexable data field

Use in AppsWH
Module Brief description