friendywill
friendywill

Reputation: 55

Can I make different sections in Word, not only have the same header and footer, but page numbers that align as one whole document

Basically, I go to "Layout" > "Page Setup" > "Margins" > "Custom Margins" then selected the "Orientation" as "Landscape" then "Apply to:" > "This point forward", this changes the orientation of the pages for the rest of the document from where the blinking cursor sits, then I repeat the process with the cursor on the next page but choose the "Orientation" to "Portrait". This is how I make a specific page in a word document landscape. When this happens it sections that landscape page as "Section 2" and the pages after that "Section 3". The problem comes with the header and footer, in each section the header and footer is different. This is especially problematic with page numbers, as each new section starts as its own thing and says it is page one at the start of that section.

I have tried "Header & Footer" > "Navigation section" > "Link to previous" for "Section 2" to "Section 1", this would not display any information at all from "Section 1" to "Section 2". For some reason when I did the same for "Section 3" to "Section 2", "Section 3" would display the information of "Section 2", this does not solve the page numbering issue though because "Section 3" starts off as page 1. So it is weird to me how the "Link to previous" feature worked only on "Section 3" and not "Section 2".

If anyone has any method of fixing this I would be grateful :D, I will also be grateful for any dodgy ways of getting around it but I will not mark it as an answer.

Upvotes: 0

Views: 474

Answers (1)

Charles Kenyon
Charles Kenyon

Reputation: 1028

I would add this as a comment but am new and not allowed to comment. This would be better handled on the Microsoft Answers site as it about general Word features rather than programming.

That said, what happened was when you created a new section, likely before you did the orientation shift, you told Word to restart numbering at 1. Word took that as the way to start new sections. You can manually go to each new section and use the format page number dialog to tell word to continue from previous.

It sounds as if you may also have "different first page" set. This is a setting that continues into new sections as well. Header/footer settings with multiple sections and their interactions get complex. It is summarized here: Header/Footer Settings Recap.

You can download an Add-In from my site that will do this for you. Continuous Page Numbers Add-In. That uses a macro to do this.

Sub ContinuousPageNumbersMacro()
'
' ContinuousPageNumbersMacro Macro
' This macro makes page numbering continuous througout document. This is for multisection documents where it may be hard to find page breaks and figure out page numbering changes.
'
' Jay Freedman
' http://answers.microsoft.com/en-us/office/forum/office_2007-word/page-numbers-are-all-fouled-up-in-my-large/d188687e-9663-43e0-a450-1dbadc47f09f
' Can be used as straight macro or attached to keyboard shortcut
' modified to preserve track changes status - idea from Graham Mayor 25 Oct 2017
'
    Dim secNum As Long
    Dim btnCancel ' give user chance to cancel
    Dim bTrackChanges As Boolean
    Dim strVersion As String
    strVersion = ThisDocument.CustomDocumentProperties("Version").Value
    btnCancel = MsgBox(prompt:="Do you want to reset all of the page numbers in this document to number continuously?", _
        Title:="Continuous Page Numbering Version " & strVersion & "  Are you sure?", _
        Buttons:=vbYesNo)
    If btnCancel = vbNo Then
        MsgBox prompt:="Reset of continuous page numbering cancelled by user!", Buttons:=vbExclamation, Title:="Page Number Reset Cancelled!"
        Exit Sub
    End If
'   Proceed with reset
    bTrackChanges = ActiveDocument.TrackRevisions 'Graham Mayor
    ActiveDocument.TrackRevisions = False ' Graham Mayor
    With ActiveDocument
        For secNum = 2 To .Sections.Count
            .Sections(secNum).Headers(wdHeaderFooterPrimary) _
                 .PageNumbers.RestartNumberingAtSection = False
        Next
    End With
    ActiveDocument.TrackRevisions = bTrackChanges 'Graham Mayor
    MsgBox prompt:="The Continuous Page Numbers macro has run.", Title:="Page number reset macro finished!"
End Sub

Upvotes: 0

Related Questions