![]() Word.HeaderFooter ftr = ĭoc. = ĭoc. = Word.WdColorIndex. Highlight the text within the header or footer (whichever text you would like to delete). Switch between Header and Footer: This allows you to jump quickly between the header and footer on a page. This snippet assumes the document has but the one section, and no different first page. Page Setup: This opens the Page Setup dialog box so you can adjust the location of the header and footer. Have you gone to View> Header and Footer to access that layer of the document Word has no provision for putting any info re the printer into a Header or Footer. Note that Word documents can be extremely complex, with multiple Section objects, and each section object can have a "normal" header and footers as well as optionally a different header and footer for the first page. The snippet also demonstrates how to access a document's default Header and Footer. ![]() The difference in my code is that it uses Document.Content which returns the Range for the main body of the document without needing to specify start and end values. The first changes the base style that underlies most of the font formatting you'll find in Word the second is basically what you have - applying the formatting as if you'd select the body of the document and format it. I used the font color to make things more obvious. The following snippet shows two alternatives for changing the font. ![]() I'm assuming the code you show us works for you as far as changing the font and saving the document.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |