Kindly check my code below, in InvestigationSection in the last footer, there is a table I want to hide (Just in the last footer for the section)
- Code: Select all
Section InvestigationSection = document.AddSection();
InvestigationSection.PageSetup.InsertPageNumbers(false, Spire.Doc.Documents.PageNumberAlignment.Left);
InvestigationSection.AddParagraph().AppendHTML(InvestigationContent);
InvestigationSection.HeadersFooters.LinkToPrevious = false;// added by jane
InvestigationSection.HeadersFooters.Header.AddParagraph().AppendHTML(Header);
InvestigationSection.HeadersFooters.Footer.AddParagraph().AppendHTML(InvestigationFooter);
InvestigationSection.Paragraphs[InvestigationSection.Paragraphs.Count - 1].InsertSectionBreak(Spire.Doc.Documents.SectionBreakType.NoBreak);
// Decision Section
Section DecisionSection = null;
if (DecisionContent.Length > 0)
{
DecisionSection = document.AddSection();
DecisionSection.AddParagraph().AppendHTML(DecisionContent);
DecisionSection.HeadersFooters.LinkToPrevious = false;// added by jane
DecisionSection.HeadersFooters.Header.AddParagraph().AppendHTML(Header);
DecisionSection.HeadersFooters.Footer.AddParagraph().AppendHTML(DecisionFooter);
}
ms = new MemoryStream();
document.SaveToStream(ms, FileFormat.Docx);
Regards,