Consecutive page numbers

B

Babyjsmom

Is there any way to have a one page document print out with consecutive page
numbers on it? Example: as it prints the same document over and over again
100 times each one has a new page number on it.
 
G

Greg

You can use the following macro:

Sub PrintNumberedCopeis()

Dim NumCopies, CopyNumber As String
Dim Counter As Long
Dim rng1 As Range
CopyNumber = Val(InputBox("Enter the starting
number.", "Starting Number", 1))
NumCopies = Val(InputBox("Enter the number of copies that
you want to print", "Print", 1))
With ActiveDocument.Bookmarks
.Add Name:="CopyNum"
End With
Set rng1 = ActiveDocument.Bookmarks("CopyNum").Range
Counter = 0
While Counter < NumCopies
rng1.Delete
rng1.Text = CopyNumber
ActiveDocument.PrintOut
CopyNumber = CopyNumber + 1
Counter = Counter + 1
Wend
With ActiveDocument.Bookmarks
.Add Name:="CopyNum", Range:=rng1
End With
End Sub
 
Top