Vielleicht hängts an den vielen Remove. Versuch mal mittels .Update alle Rich Text Operationen abzuschließen bevor das Script weiterläuft.
If Not (body Is Nothing) Then
Set tmpRTI=cdoc.CreateRichTextItem("tmpRTI")
If Not (tmpRTI Is Nothing) Then
Call tmpRTI.AppendText(cDoc.kontaktIntern(0) & ": " & Chr(13))
Call tmpRTI.AppendRTItem(body)
call tmpRTI.Update
Call cDoc.RemoveItem("Body")
Set Body=cdoc.CreateRichTextItem("Body")
Call body.AppendRTItem(tmpRTI)
call body.Update
Call cDoc.RemoveItem("tmpRTI")
End If
End If
cdoc.save True, False, True
Hintergrund:
Processes all pending operations on a rich text item.
Hinweis This method is new with Release 6.
Defined in
NotesRichTextItem
Syntax
Call notesRichTextItem.Update
Usage
Operations on a rich text item are queued for efficiency. The order and time of completion are not predictable. Use this method to ensure that processing is complete at a certain point.
This method is useful when interacting with the front-end classes.
Andreas