Monday, 4 April 2011

Button to open db on a particular server

We have many servers in our environment and we try to make sure users use their local server for their applications.  Below is a simple button to force a user to open an application on a particular server, which will place this replica on top of their replica stack.

Sub Click(Source As Button)
Dim workspace As New NotesUIWorkspace
Dim db As New NotesDatabase( "", "" )

If db.OpenByReplicaID( "<SERVER_NAME>", "<REPLICAID>" ) Then
Call workspace.OpenDatabase ( db.Server, db.FilePath)
End If
End Sub

No comments:

Post a Comment