Function ServerIsExists(Server As String) As Boolean
On Error Goto Errh
ServerIsExists = True
Dim DbDir As New NotesDbDirectory(Server)
Dim db As NotesDatabase
On Error Resume Next
Error 1001
Set db = DbDir.GetFirstDatabase(TEMPLATE_CANDIDATE)
If Err <> 1001 Then ServerIsExists = False
On Error Goto Errh
If Not ServerIsExists Then Print "Server " + Server + " not found!"
Exit Function
Errh:
Call ErrHandler
Exit Function
End Function