Loading...
 

PutObject

PutObject

PutObject(windowID, childID), PutObject(, childID), PutObject

parameters: Identifier of a Windows and a child Windows object

Stack
Stack Position Description
Stack(In) Top one object
Stack(Out) Top -

While PutValue sends a string to a Window object, PutObject gives it an object whose data it imports. PutObject can only be applied to the interface objects listed in the following table, and - according to the function of the Window object - only certain objects are accepted:

Numeric CX_NUMERIC, CX_VALUE, CX_PERCENT, CX_BOOLEAN
Percent CX_PERCENT, CX_VALUE, CX_PERCENT, CX_BOOLEAN
Fraction CX_FRACTION
Date CX_DATE, CX_DIFFUSE_DATE, CX_SPAN_DATE
DigitalTime CX_TIME, CX_SPAN_TIME
Picture CX_BITMAP

Example

When clicking on the button "Apply system date" the current system date is dragged and written to the window object "SessionDate" via PutObject:

Window(EditWin, SELECT_MULTIPLE, NO_SIZE, 310, 87, 500, 60, T("Sitzungsdatum", "Session date"))
{
  Prompt(SessionDatePmt, 11, 4, T("Sitzungsdatum", "Session date"))
  Date(SessionDate, 175, 4, 88)

  Button(SystemDateAsSessionDateBtn, 290, 3, 190, 10, T("Übernehme Systemdatum", "Get system date"))
  SELECT: SystemObject Call(SystemDate) PutObject(, SessionDate) " rel=""> SELECT: SystemObject Call(SystemDate) PutObject(, SessionDate)
}