Public Function fktNotesTerminLoeschen(strServer As String, strMailDB As String, strNotesID As String) Dim objNotes As Object Dim LNdb As Object Dim LNView As Object Dim Collection As Object 'Holen einer aktiven Notessession Set objNotes = GetObject("", "Notes.NotesSession") 'Verweisen auf die gewünschte Datenbank Set LNdb = objNotes.GETDATABASE(strServer, strMailDB, False) If Not (LNdb Is Nothing) Then Set LNView = LNdb.GETVIEW("($ApptUNID)") If LNView Is Nothing = False Then 'Collection füllen Set Collection = LNView.GETALLDOCUMENTSBYKEY(strNotesID, True) If Collection.Count > 0 Then Collection.RemoveAll True End If End If End If Set objNotes = Nothing Set LNdb = Nothing Set LNView = Nothing Set Collection = Nothing End Function