Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #5  
Old 10-06-2016, 12:10 AM
gmayor's Avatar
gmayor gmayor is offline Macro for inserting and formatting headers and footers Windows 10 Macro for inserting and formatting headers and footers Office 2016
Expert
 
Join Date: Aug 2014
Posts: 4,144
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Add the two lines as shown below
Code:
Sub ReplaceHeaderFooter(ByVal oDoc As Document)
Dim oSec As Section
Dim oHead As HeaderFooter
Dim oFoot As HeaderFooter
Dim oRng As Range
Dim oShape As InlineShape
    For Each oSec In oDoc.Sections
        oSec.PageSetup.HeaderDistance = InchesToPoints(0.06)
        oSec.PageSetup.FooterDistance = InchesToPoints(0#)
        For Each oHead In oSec.Headers
'etc
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
 

Tags
letterhead

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Macro for inserting and formatting headers and footers headers/footers scot Word 3 05-22-2015 09:45 AM
Macro for find/replace (including headers and footers) for multiple documents jpb103 Word VBA 2 05-16-2014 04:59 AM
Macro for inserting and formatting headers and footers Headers and Footers Kingsmoss Word 3 04-28-2014 02:43 PM
Macro for inserting and formatting headers and footers Headers and Footers teza2k06 Word 1 05-14-2013 11:07 AM
Headers and Footers OverAchiever13 Word 1 05-27-2010 01:30 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 10:52 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft