I've a lotus script that deletes a server connection in the Lotus Notes Addressbook.
It works fine.
The only problem is that the script looks for the server name and not for the IP Address.
When I enter the IP Address the script doesn't find the server connection.
there is below connections.
When the script runs it deletes both of them.
But I will that the second connection stays there because that's the new IP.
How to do it?
Sub Click(Source As Button)
Dim s As New notessession
Dim db As notesdatabase
Dim doc As notesdocument
Set db = s.GetDatabase( "", "names.nsf", False )
If db Is Nothing Then
Msgbox "Cannot find names.nsf!"
Dim view As NotesView
Set view = db.GetView( "Connections" )
Set doc = view.GetDocumentByKey( "RMD01/SERVER/COMPANY" )
If Not ( doc Is Nothing) Then
Msgbox "The connection was deleted successfully"
Call doc.Remove( True )
Msgbox "Cannot find the old server connection"