EsbCopyApplication

Copies an existing application, either on the client or the server, to a new application, including all associated databases and objects. If the application is copied on the server, the new application is started.

Syntax

EsbCopyApplication (hCtx, hSrcCtx, AppName, nAppName)
ByVal hCtx     As Long
ByVal hSrcCtx  As Long
ByVal AppName  As String
ByVal nAppName As String
ParameterDescription

hCtx

VB API context handle.

hSrcCtx

Not used; should be same as hCtx.

AppName

Name of an existing application to copy.

nAppName

Name of a new application. See Application Name Limits.

Notes

Return Value

None.

Access

For a server application, the caller must have application Create/Delete/Edit privilege (ESB_PRIV_APPCREATE).

Example

Declare Function EsbCopyApplication Lib "ESBAPIN" (ByVal hCtx As Long, ByVal hSrcCtx As Long, ByVal SrcApp As String, ByVal DestApp As String) As Long 

Sub ESB_CopyApplication ()
   Dim sts As Long
   Dim SrcApp As String 
   Dim DestApp As String 
   Dim hSrcCtx As Long   hSrcCtx = hCtx 
   SrcApp = "Sample"
   DestApp = "NewTest"   '*****************
   ' Copy Application
   '*****************
   sts = EsbCopyApplication (hCtx, hSrcCtx,
   SrcApp, DestApp)
End Sub

See Also