# EssLogSize

Description

EssLogSize() returns the size of the Agent log file (`ESSBASE.LOG`), or of the Server log file (`APPNAME.LOG`).

Syntax

    ESS_FUNC_M EssLogSize (hCtx, AgentLog, pszAppName, pulLogSize);

ESS_HCTX_T | hCtx
ESS_BOOL_T | AgentLog
ESS_STR_T | pszAppName
ESS_PULONG_T | pulLogSize

Parameters

hCtx | Essbase API context handle.
AgentLog | If TRUE, the size of the Agent log file (`ESSBASE.LOG`) is returned. If FALSE, the size of the Server log file (`APPNAME.LOG`) is returned.
pszAppName | Application name.
pulLogSize | Size of log file returned.

Return Value

Returns a zero if successful.

Notes

- The Agent log file (`ESSBASE.LOG`) and the Server log file (`APPNAME.LOG`) are located on the server in the ARBORPATH directory. Use EssGetLogFile() to view message logs.

Access

This function does not require the caller to have access privileges.

Example

    ESS_FUNC_M ESS_LogSize (ESS_HCTX_T hCtx)
    {
       ESS_STR_T     pszAppName = NULL;
       ESS_ULONG_T   ulLogSize = 0;
       ESS_FUNC_M     sts = ESS_STS_NOERR;

       pszAppName = "Sample";

       /*
        * Get the log file size for the "Sample" application.
        */
       sts = EssLogSize(hCtx, ESS_FALSE, pszAppName, &ulLogSize);

       return(sts);
    }

See Also

EssDeleteLogFile()
EssGetLogFile()
EssWriteToLogFile()