Returns the parent of a member.
Syntax
ESS_FUNC_M EssOtlGetParent (hOutline, hMember, phMember);
Parameter | Data Type | Description |
---|---|---|
hOutline | ESS_HOUTLINE_T | Outline context handle. |
hMember | ESS_HMEMBER_T | Handle of member to retrieve the parent of. |
phMember | ESS_PHMEMBER_T | Pointer for return of a member handle of the parent of the hMember parameter. |
Notes
If there is no parent, *phMember is set to ESS_NULL and the call returns 0. (The hMember is a dimension.)
Return Value
Returns 0 if successful.
Example
#include <essapi.h> #include <essotl.h> ESS_STS_T sts = 0; ESS_HOUTLINE_T hOutline; ESS_HMEMBER_T hMemberChild; ESS_HMEMBER_T hMemberParent; ESS_OBJDEF_T Object; ESS_APPNAME_T szAppName; ESS_DBNAME_T szDbName; ESS_OBJNAME_T szFileName; memset(&Object, '\0', sizeof(Object)); Object.hCtx = hCtx; Object.ObjType = ESS_OBJTYPE_OUTLINE; strcpy(szAppName, "Sample"); strcpy(szDbName, "Basic"); strcpy(szFileName, "Basic"); Object.AppName = szAppName; Object.DbName = szDbName; Object.FileName = szFileName; sts = EssOtlOpenOutline(hCtx, &Object, ESS_TRUE, ESS_TRUE, &hOutline); if (!sts) { sts = EssOtlFindMember(hOutline, "Jan", &hMemberChild); } if (!sts && hMemberChild) { sts = EssOtlGetParent(hOutline, hMemberChild, &hMemberParent); }
See Also