Aspose.Slides for Node.js: Table Row Clone and Font Styles

Hi team, I’m using aspose slides via java for nodejs. Can you please guide me how can I clone a row in a table above or below a specific index. Also can you please tell me how to remove all existing font styles if we have clone a row and we did not want all styles from there to a new row.

@karanmarsh,
Thank you for contacting support. I am working on your questions and will get back to you soon.

@karanmarsh,
Thank you for your patience. When you clone a table row, it is cloned as is (with text and font styles) but you can set your content and styles, or try to reset them using the following code snippet:

presentation = new aspose.slides.Presentation("sample.pptx");

// Let the table be the first shape on the first slide.
table = presentation.getSlides().get_Item(0).getShapes().get_Item(0);

originalRowIndex = 1;
clonedRowIndex = 3;

originalRow = table.getRows().get_Item(originalRowIndex);
clonedRows = table.getRows().insertClone(clonedRowIndex, originalRow, true);

for (let i = 0; i < clonedRows.length; i++)
    for (let j = 0; j < clonedRows[i].size(); j++)
        clonedRows[i].get_Item(j).getTextFrame().getParagraphs().clear();

presentation.save("output.pptx", aspose.slides.SaveFormat.Pptx);
presentation.dispose();