Aspose.Words.Examples.CSharp.Loading_Saving.DocumentPageSplitter.GetDocumentOfPageRange C# (CSharp) Метод

GetDocumentOfPageRange() публичный Метод

Gets the document of a page range.
public GetDocumentOfPageRange ( int startIndex, int endIndex ) : Document
startIndex int 1-based index of the start page.
endIndex int 1-based index of the end page.
Результат Document
        public Document GetDocumentOfPageRange(int startIndex, int endIndex)
        {
            
            Document result = (Document)Document.Clone(false);

            foreach (Section section in mPageNumberFinder.RetrieveAllNodesOnPages(startIndex, endIndex, NodeType.Section))
                result.AppendChild(result.ImportNode(section, true));

            return result;
           
        }