This method applies transactions on each destination server defined for the project.
Syntax
ReplicationClient.Commit
Remarks
You must have Site Server Publishing administrator privileges on the server to call this method.
Use this method to apply any pending replications in a replication session (a session where you call the Connect method to initiate the session, perform replications with either the SendFile method or the DeleteFile method, and sever the connection with the Disconnect method). This method has no effect if the Content Deployment server is running in “connectionless” mode (you are issuing individual SendFile and DeleteFile method calls where they transparently do the connect and disconnect operations).
Example
The following example opens project named Project1, deletes a file, sends a file, and commits the transactions.
Option Explicit
On Error Resume Next
dim Client
set Client = CreateObject("CrsApi.ReplicationClient")
Client.Initialize("Project1")
Client.Connect
Client.DeleteFile("oldfile.htm")
Client.SendFile("newfile.htm")
Client.Commit
...
Client.Disconnect
'Release Client object
set Client = Nothing
See Also