Hi,
I am working on an project using ASP.net 2.0 and Aspose.Words 5.2
When trying to merge a number of documents, containing footnotes and endnotes, generated earlier into a big document FootnoteOptions and EndnoteOptions on the big document are not taken in account.
Here is the code:
Aspose.Words.Document masterDocument = new Aspose.Words.Document(BigTemplate);
masterDocument.FootnoteOptions.Location = FootnoteLocation.BottomOfPage;
masterDocument.FootnoteOptions.RestartRule = FootnoteNumberingRule.RestartSection;
masterDocument.FootnoteOptions.NumberStyle = NumberStyle.Ordinal;
masterDocument.FootnoteOptions.StartNumber = 1;
masterDocument.EndnoteOptions.Location = FootnoteLocation.EndOfSection;
masterDocument.EndnoteOptions.RestartRule = FootnoteNumberingRule.RestartSection;
masterDocument.EndnoteOptions.NumberStyle = NumberStyle.Ordinal;
masterDocument.EndnoteOptions.StartNumber = 1;
foreach (string documentPath in AllDocuments)
{
Aspose.Word.Document child = new Aspose.Word.Document(documentPath);
foreach (Section section in child.Sections)
{
Section dstSection = (Section)masterDocument.ImportNode(section, true, ImportFormatMode.UseDestinationStyles);
masterDocument.Sections.Add(dstSection);
}
}
Each child document contains a single section.
masterDocument.Save(masterDocumentPath);
Document generated by saving masterDocument does not restart numbering on endnotes and footnotes when a new section start.
All endnotes in the generated document are positioned at the end of the document, instead of end of section as instructed (masterDocument.EndnoteOptions.Location = FootnoteLocation.EndOfSection).
Am i doing somethig wrong?