Deletes an existing object.
Syntax
ESS_FUNC_M EssDeleteObject (hCtx, ObjType, AppName, DbName, ObjName);
| Parameter | Data Type | Description |
|---|---|---|
hCtx | ESS_HCTX_T | API context handle. |
ObjType | ESS_OBJTYPE_T | Object type (must be single type). |
AppName | ESS_STR_T | Application name. |
DbName | ESS_STR_T | Database name. If NULL, uses the application subdirectory. |
ObjName | ESS_STR_T | Object name to delete. |
Notes
To delete an object, the object must not be locked.
Outline objects cannot be deleted. Use the EssDeleteDatabase() function to delete a database, including its associated outline.
Return Value
None.
Access
This function requires the caller to have Application or Database Design privilege (ESS_PRIV_APPDESIGN or ESS_PRIV_DBDESIGN) for the specified application or database containing the object.
Example
ESS_FUNC_M
ESS_DeleteObject (ESS_HCTX_T hCtx)
{
ESS_FUNC_M sts = ESS_STS_NOERR;
ESS_STR_T AppName;
ESS_STR_T DbName;
ESS_STR_T ObjName;
ESS_OBJTYPE_T ObjType;
AppName = "Sample";
DbName = "Basic";
ObjName = "Test";
ObjType = ESS_OBJTYPE_TEXT;
sts = EssDeleteObject(hCtx, ObjType, AppName,
DbName, ObjName);
return (sts);
}See Also