# EssSetDefaultCalc

Description

EssSetDefaultCalc() sets the default calc script for the active database.

Syntax

    ESS_FUNC_M  EssSetDefaultCalc (hCtx, CalcScript);

ESS_HCTX_T | hCtx
ESS_STR_T | CalcScript

Parameters

hCtx | Essbase API context handle.
CalcScript | Default calc script string.

Return Value

None.

Notes

- The calc script string must not be greater than 64 Kbytes long.

Access

This function requires the caller to have calc privilege (ESS_PRIV_CALC) to the active database.

Example

    ESS_FUNC_M
    ESS_SetDefaultCalc (ESS_HCTX_T   hCtx)
    {
       ESS_FUNC_M           sts = ESS_STS_NOERR;
       sts = EssSetDefaultCalc (hCtx, "CALC ALL;");

      return (sts);
    }

See Also

EssDefaultCalc()
EssGetDefaultCalc()
EssSetActive()
EssSetDefaultCalcFile()