EsbSetDefaultCalcFile() sets the default calc script for the active database from a calc script file.
EsbSetDefaultCalcFile (hDestCtx, hSrcCtx, AppName, DbName, FileName)
ByVal hDestCtx As Long ByVal hSrcCtx As Long ByVal AppName As String ByVal DbName As String ByVal FileName As String
hDestCtx | Essbase VB API context handle of a target database on the server. |
hSrcCtx | Essbase VB API context handle for the calc script file location. The calc script file can reside on the client or on the same server as the target database. |
AppName | Application name for the calc script file location. |
DbName | Database name for the calc script file location. |
FileName | Name of the default calc script file. |
Declare Function EsbSetDefaultCalcFile Lib "ESBAPIW" (ByVal hDestCtx As Long, ByVal hSrcCtx As Long, ByVal AppName As String, ByVal DbName As String, ByVal FileName As String) As Long Sub ESB_SetDefaultCalcFile () Dim sts As Long Dim AppName As String Dim DbName As String Dim FileName As String Dim hSrcCtx As Long AppName = "Sample" DbName = "Basic" '*************************************** ' Calc script is an object at the server * '*************************************** hSrcCtx = hCtx FileName = "calc" '********** ' Calc File '********** sts = EsbSetDefaultCalcFile (hCtx, hSrcCtx, AppName, DbName, FileName) End SubEsbDefaultCalc()