# EssSetGlobalState

Description

EssSetGlobalState() sets the server global state structure which contains parameters for system administration.

Syntax

    ESS_FUNC_M EssSetGlobalState (hCtx, pGlobal);

ESS_HCTX_T | hCtx
ESS_PGLOBAL_T | pGlobal

Parameters

hCtx | Essbase API context handle.
pGlobal | Pointer to global state structure.

Return Value

None.

Notes

- When changing parameter values, it is advisable to call EssGetGlobalState() first to get the correct values of any parameters you do not wish to change.

Access

This function requires the caller to be a supervisor.

Example

    ESS_FUNC_M
    ESS_SetGlobalState (ESS_HCTX_T hCtx)
    {
       ESS_FUNC_M       sts = ESS_STS_NOERR;
       ESS_GLOBAL_T    Global;

       /* Initialize Global State */
       Global.Security = 1;
       Global.Logins = 1;
       Global.Access = ESS_ACCESS_NONE;
       Global.Validity = 200;
       Global.Currency = 1;
       Global.PwMin = 8;
       Global.InactivityTime = 3600;
       Global.InactivityCheck = 300;

       sts = EssSetGlobalState(hCtx, &Global);
       return (sts);
    }

See Also

EssGetGlobalState()