By Romil Handoo
In one of my XPages, I have written the following code to copy the content of one rich text item into another. Both rich text items are within different documents.
var docChild : NotesDocument = database.createDocument();
var rt_Parent : NotesRichTextItem = docParent.getDocument().getFirstItem(“Body_1”);
var rt_Child : NotesRichTextItem = docChild.createRichTextItem(“Body”);
Here docParent is the document associated with current XPage (as data source). When trying to execute the code, I am getting the following error:
Method NotesRichTextItem.appendRTItem(lotus.domino.local.Item) not found, or illegal parameters
Someone guide me how to fix the issue, and what is the proper way to copy an RT item from one document to another (field name of RT item is different in source and destination documents).
Source: Stack Overflow