Converts a unique-member-name outline to an outline that allows duplicate names.
When pInfo ->fNonUniqueName is set to TRUE, this function converts a unique member name outline to an outline allowing duplicate member names. You cannot convert an outline allowing duplicate member names back to a unique member name outline.
Syntax
ESS_FUNC_M EssOtlSetOutlineInfoEx (hOutline, pInfo);
Parameter | Data Type | Description |
---|---|---|
hOutline | ESS_HOUTLINE_T | Outline context handle (input). |
pInfo | ESS_OUTLINEINFO_T | Pointer to a structure allocated by the caller to store outline information (input). |
Notes
Only some of the fields of the ESS_OUTLINEINFO_T structure are used to set information. See the structure description for more information.
Return Value
Returns 0 if successful; otherwise, see the Outline API C Outline API Error Return Values.
Example
void SetOutlineInfoEx()
{
ESS_STS_T sts = 0;
ESS_POUTLINEINFO_T pInfo = ESS_NULL;
ESS_HOUTLINE_T hOutline;
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 = EssOtlGetOutlineInfo(hOutline, &pInfo);
}
if (!sts && pInfo)
{
pInfo->fNonUniqueName = ESS_TRUE;
sts = EssOtlSetOutlineInfoEx(hOutline, pInfo);
}
if (!sts)
{
sts = EssOtlWriteOutline(hOutline, &Object);
}
if (!sts)
{
sts = EssOtlRestructure(hCtx, ESS_DOR_ALLDATA);
}
if (pInfo)
{
EssFree(hInst, pInfo);
}
}
See Also