I am using WORD 97 onwards, I need to print 4 copies of a document, but need
to update a field in the document on each copy.

Is there a way that this can be done?

If so, would someone be kind enough to provide me with some code.

Thanks in anticipation.

--

Mark

Re: Pause printing between copies by Jean-Guy

Jean-Guy
Thu Dec 15 12:12:10 CST 2005

Mark was telling us:
Mark nous racontait que :

> I am using WORD 97 onwards, I need to print 4 copies of a document,
> but need to update a field in the document on each copy.
>

How do you plan on updating the field?

--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
jmarcilREMOVE@CAPSsympatico.caTHISTOO
Word MVP site: http://www.word.mvps.org



Re: Pause printing between copies by mark

mark
Thu Dec 15 12:23:02 CST 2005

I was thinking on the lines of:

ActiveDocument.formfields("type").Result = "This is for Peter"

ActiveDocument.formfields("type").Result = "This is for John"

etc....


--
Mark A Whitehead



"Jean-Guy Marcil" wrote:

> Mark was telling us:
> Mark nous racontait que :
>
> > I am using WORD 97 onwards, I need to print 4 copies of a document,
> > but need to update a field in the document on each copy.
> >
>
> How do you plan on updating the field?
>
> --
> Salut!
> _______________________________________
> Jean-Guy Marcil - Word MVP
> jmarcilREMOVE@CAPSsympatico.caTHISTOO
> Word MVP site: http://www.word.mvps.org
>
>
>

Re: Pause printing between copies by Jean-Guy

Jean-Guy
Thu Dec 15 13:01:09 CST 2005

Mark was telling us:
Mark nous racontait que :

> I was thinking on the lines of:
>
> ActiveDocument.formfields("type").Result = "This is for Peter"
>
> ActiveDocument.formfields("type").Result = "This is for John"

Try this:

'_______________________________________
Option Explicit

'_______________________________________
Sub PrintCopies()

Dim MyBackgroudOptions As Boolean
Dim GetText As String
Dim GetNumber As String
Dim i As Long

MyBackgroudOptions = Options.PrintBackground
Options.PrintBackground = False

Do
GetNumber = InputBox("How many copies do you need.", _
"Print Out Count")
Loop While Not IsNumeric(GetNumber) And Not GetNumber = ""

If GetNumber = "" Then GoTo LeaveSub

For i = 1 To CLng(GetNumber)
GetText = InputBox("Type the text to use for copy number " _
& i & ".", "Print Copies")

If Not GetText = "" Then
Myprintout GetText
End If
Next

LeaveSub:
Options.PrintBackground = MyBackgroudOptions

End Sub
'_______________________________________


'_______________________________________
Function Myprintout(FieldText As String) As Boolean

With ActiveDocument
.FormFields("type").Result = FieldText
.PrintOut
End With

End Function
'_______________________________________

--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
jmarcilREMOVE@CAPSsympatico.caTHISTOO
Word MVP site: http://www.word.mvps.org



Re: Pause printing between copies by mark

mark
Thu Dec 15 14:26:03 CST 2005

Jean-Guy,

Fantastic, thank you

--
Mark


"Jean-Guy Marcil" wrote:

> Mark was telling us:
> Mark nous racontait que :
>
> > I was thinking on the lines of:
> >
> > ActiveDocument.formfields("type").Result = "This is for Peter"
> >
> > ActiveDocument.formfields("type").Result = "This is for John"
>
> Try this:
>
> '_______________________________________
> Option Explicit
>
> '_______________________________________
> Sub PrintCopies()
>
> Dim MyBackgroudOptions As Boolean
> Dim GetText As String
> Dim GetNumber As String
> Dim i As Long
>
> MyBackgroudOptions = Options.PrintBackground
> Options.PrintBackground = False
>
> Do
> GetNumber = InputBox("How many copies do you need.", _
> "Print Out Count")
> Loop While Not IsNumeric(GetNumber) And Not GetNumber = ""
>
> If GetNumber = "" Then GoTo LeaveSub
>
> For i = 1 To CLng(GetNumber)
> GetText = InputBox("Type the text to use for copy number " _
> & i & ".", "Print Copies")
>
> If Not GetText = "" Then
> Myprintout GetText
> End If
> Next
>
> LeaveSub:
> Options.PrintBackground = MyBackgroudOptions
>
> End Sub
> '_______________________________________
>
>
> '_______________________________________
> Function Myprintout(FieldText As String) As Boolean
>
> With ActiveDocument
> .FormFields("type").Result = FieldText
> .PrintOut
> End With
>
> End Function
> '_______________________________________
>
> --
> Salut!
> _______________________________________
> Jean-Guy Marcil - Word MVP
> jmarcilREMOVE@CAPSsympatico.caTHISTOO
> Word MVP site: http://www.word.mvps.org
>
>
>