Copy
Creates a paragraph copy. Ingnore comments, footnote references, complex fields.
Syntax
expression.Copy();
expression - A variable that represents a ApiParagraph class.
Parameters
This method doesn't have any parameters.
Returns
Example
Duplicate a paragraph and append the copy to the end of a document.
// How do I copy a paragraph and place it elsewhere in a document?
// Reuse existing paragraph content without retyping it in a document.
let doc = Api.GetDocument();
let paragraph1 = doc.GetElement(0);
paragraph1.AddText("This is just a sample text that was copied.");
let paragraph2 = paragraph1.Copy();
doc.Push(paragraph2);