ApiExamples.ExSection.ModifyPageSetupInAllSections C# (CSharp) Метод

ModifyPageSetupInAllSections() приватный Метод

private ModifyPageSetupInAllSections ( ) : void
Результат void
        public void ModifyPageSetupInAllSections()
        {
            //ExStart
            //ExId:ModifyPageSetupInAllSections
            //ExSummary:Shows how to set paper size for the whole document.
            Document doc = new Document(MyDir + "Section.ModifyPageSetupInAllSections.doc");

            // It is important to understand that a document can contain many sections and each
            // section has its own page setup. In this case we want to modify them all.
            foreach (Section section in doc)
                section.PageSetup.PaperSize = PaperSize.Letter;

            doc.Save(MyDir + @"\Artifacts\Section.ModifyPageSetupInAllSections.doc");
            //ExEnd
        }