Function
The function OpenObject opens an object for the user process. Each change of a value or status of opened object will be sent by the process D2000 Server to the user process, which can process the value using the function NewValueProc.
Declaration
APIRET OpenObject(const char *name, BasObjInfoPtr data)

Parameters
The parameter name defines the name of opened object and the structure data will contain returned information on the opened object. The item data.Id defines an unique object identifier, which can be used later in the function NewValueProc to detect the object name and in the function CloseObject used to close defined object.
Return code
Code Description
API_OK Object opened correctly.
API_ObjNotExist Required object doesn't exist.
API_TimeoutError Object was not opened in given time.
API_ParamError The value of the parameter data is null.

0 komentárov

Nie ste prihlásený. Akékoľvek zmeny, ktoré vykonáte, sa označia ako anonymné. Ak už máte svoj účet, pravdepodobne sa budete chcieť prihlásiť .