例: MoveReplica method

次のエージェントは、Guys1.nsf を Company_Server から Software_Server に移動します。

Sub Initialize
  Dim session As New NotesSession
  Dim adminp As NotesAdministrationProcess
  Set adminp = _
  session.CreateAdministrationProcess("Software_Server") 
  adminp.CertifierFile = _
  "c:¥lotus¥notes¥data¥software-cert.id" 
  Dim ws As New NotesUIWorkspace
  adminp.CertifierPassword = _
  ws.Prompt(PROMPT_PASSWORD, "Password", _
  "Type certifier password.")
  noteid$ = adminp.MoveReplica("Company_Server", _
  "Guys1", _
  " Software_Server")
  If noteid$ <> "" Then
    Dim db As New NotesDatabase("Software_Server", "admin4") 
    Call ws.EditDocument(False, db.GetDocumentByID(noteid$))
  End If
End Sub