Function
The function GetObjectValue is used to get a current value of a given object.
Declaration
APIRET GetObjectValue(const char *name, HOBJ id, ObjectInfoPtr data)
Parameters
The parameters name and id defines uniquely an object. One of them is required. If the parameter name is used, then id must equal to zero. The current value and status of defined object together with other information is returned in the structure data. If a value of the object is Text, Array or Structure types, the allocated memory for a value must be freed using the function FreeData.
Return code
Code Description
API_OKObject value was obtained correctly.
API_ObjNotExistRequired object doesn't exist.
API_TimeoutErrorObject value was not obtained in defined time.
API_ParamErrorThe value of the parameter data is null.
Napíšte komentár