Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Sub CheckBox31_Click()
Dim r As Word.Range
' for footers 1 = wdHeaderFooterPrimary
Set r = ActiveDocument.Sections(1).Footers(1).Range
If CheckBox31 = True Then
With r
.Text = "Draft Copy "
.Collapse Direction:=wdCollapseEnd
End With
ActiveDocument.AttachedTemplate. _
AutoTextEntries("Page X of Y").Insert _
Where:=r
Else
With r
.Text = "Revised July 2006 DEQ Form #205-002 "
End With
End If
Set r = Nothing
End Sub
With ActiveDocument.Sections(1)
Dim CurPage As String
Dim TtlPgs As String
CurPage = Selection.Information(wdActiveEndPageNumber)
TtlPgs = Selection.Information(wdNumberOfPagesInDocument)
If CheckBox31 = True Then
With r
.Text = "Draft Copy "
End With
Else
With r
.Text = "Revised July 2006 DEQ Form #205-002 "
.Collapse Direction:=wdCollapseEnd
ActiveDocument.AttachedTemplate. _
AutoTextEntries("Page X of Y").Insert _
Where:=r
End With
End If
I finally ended up using this solutionThe one that does not use fields, and uses Selection?
If you are using something different from the code you state you "ended up using", it would be polite to share with us.
What DID you end up using?
Gerry
My paintings and sculpture