Reply
 
Thread Tools Display Modes
  #1   Report Post  
nobag
 
Posts: n/a
Default Merge to printer as individual documents.

Hi there,

I'm trying to create a mail merge in word, that produces a 6 page booklet
for every person in the excel list.

I've got the data and the booklets exactly as I want them, but I have a
problem when it comes to printing them.

My printer (Panasonic DP6010) has a stapler function on it, and I want it to
staple each booklet for me. But when I merge to printer it prints all 30
booklets and staples them once.

I assume this is because the mail merge results are being sent as 1
document, not 30 seperate documents.

Is there a way round this?

Thanks for any help

  #2   Report Post  
Peter Jamieson
 
Posts: n/a
Default

This question pops up from time to time. The main possibilities are as
follows - (c) has definitely worked in other cases:
a. have a good look at the printer driver options, and see if there is any
way you can trigger the stapling action by, e.g. specifying that page or
perhaps the last page comes from a different bin. I doubt it, but worth
looking.
b. if you have a detailed technical manual for the printer that tells you
what sequence to send to trigger the stapling action, you may be able to put
that sequence into a { PRINT } field at the beginning or end of your
document. Again, PRINT only works in certain circumstances so it's a long
shot. You might also be able to work out what control sequence or postscript
code is used to trigger stapling by checking the "print to file" option in
File|Print and comparing the output of "stapled" and "non-stapled" documents
in e.g. Notepad. Also a long shot. You may find with Word XP you can issue
the corrct sequence in some way using Word Mailmerge events.
c. Instead of doing one merge for all the records in your data source, use
VBA to do one merge for each record in your data source. You should then see
one print job per packet rather than a 1500 page print job. Some starting
point code is as follows - you may find see the Print dialog for each merge,
depending on the version of Word. If your merge processes multiple source
data records per packet you will obviously need to modify the source code.

Sub OneMergePerSourceRec()
'

' NB, needs bettor error management and doubtless other things a VBA expert
' will point out.

Dim intSourceRecord
Dim objMerge As Word.MailMerge
Dim strOutputDocumentName As String
Dim TerminateMerge As Boolean


' Need to set up this object as the ActiveDocument changes when the
' merge is performed. Besides, it's clearer.

Set objMerge = ActiveDocument.MailMerge
With objMerge

' If no data source has been defined, do it here using OpenDataSource.
' But if it is already defined in the document, you should not need to
define it here.

' .OpenDataSource _
' Name:="whatever"

intSourceRecord = 1
TerminateMerge = False

Do Until TerminateMerge
.DataSource.ActiveRecord = intSourceRecord

' if we have gone past the end (and possibly, if there are no records)
' then the Activerecord will not be what we have just tried to set it to

If .DataSource.ActiveRecord intSourceRecord Then
TerminateMerge = True
' the record exists
Else

.DataSource.FirstRecord = intSourceRecord
.DataSource.LastRecord = intSourceRecord
.Destination = wdSendToPrinter
.Execute
intSourceRecord = intSourceRecord + 1
End If
Loop
End With
End Sub

d. Perform the merge to an output file and print each section in turn - you
would need to change this if you have more than one section in your mail
merge main document.

Sub PrintEachSection()
Dim iSectionCount As Integer
For iSectionCount = 1 To ActiveDocument.Sections.Count
ActiveDocument.PrintOut Range:=wdPrintFromTo, From:="s" & iSectionCount,
To:="s" & iSectionCount
Next iSectionCount
End Sub

--
Peter Jamieson

"nobag" wrote in message
...
Hi there,

I'm trying to create a mail merge in word, that produces a 6 page booklet
for every person in the excel list.

I've got the data and the booklets exactly as I want them, but I have a
problem when it comes to printing them.

My printer (Panasonic DP6010) has a stapler function on it, and I want it
to
staple each booklet for me. But when I merge to printer it prints all 30
booklets and staples them once.

I assume this is because the mail merge results are being sent as 1
document, not 30 seperate documents.

Is there a way round this?

Thanks for any help



  #3   Report Post  
nobag
 
Posts: n/a
Default

Hi, and thanks for your such detailed reply.

I've used a macro to merge to seperate documents, and then select all in
windows explorer, right click and select print.

It's a slow, un-elegant way of doing it, but it works at the minute.
I am going to have a look at finding the staple command from the printer.

Thanks again.
Chris


"Peter Jamieson" wrote:

This question pops up from time to time. The main possibilities are as
follows - (c) has definitely worked in other cases:
a. have a good look at the printer driver options, and see if there is any
way you can trigger the stapling action by, e.g. specifying that page or
perhaps the last page comes from a different bin. I doubt it, but worth
looking.
b. if you have a detailed technical manual for the printer that tells you
what sequence to send to trigger the stapling action, you may be able to put
that sequence into a { PRINT } field at the beginning or end of your
document. Again, PRINT only works in certain circumstances so it's a long
shot. You might also be able to work out what control sequence or postscript
code is used to trigger stapling by checking the "print to file" option in
File|Print and comparing the output of "stapled" and "non-stapled" documents
in e.g. Notepad. Also a long shot. You may find with Word XP you can issue
the corrct sequence in some way using Word Mailmerge events.
c. Instead of doing one merge for all the records in your data source, use
VBA to do one merge for each record in your data source. You should then see
one print job per packet rather than a 1500 page print job. Some starting
point code is as follows - you may find see the Print dialog for each merge,
depending on the version of Word. If your merge processes multiple source
data records per packet you will obviously need to modify the source code.

Sub OneMergePerSourceRec()
'

' NB, needs bettor error management and doubtless other things a VBA expert
' will point out.

Dim intSourceRecord
Dim objMerge As Word.MailMerge
Dim strOutputDocumentName As String
Dim TerminateMerge As Boolean


' Need to set up this object as the ActiveDocument changes when the
' merge is performed. Besides, it's clearer.

Set objMerge = ActiveDocument.MailMerge
With objMerge

' If no data source has been defined, do it here using OpenDataSource.
' But if it is already defined in the document, you should not need to
define it here.

' .OpenDataSource _
' Name:="whatever"

intSourceRecord = 1
TerminateMerge = False

Do Until TerminateMerge
.DataSource.ActiveRecord = intSourceRecord

' if we have gone past the end (and possibly, if there are no records)
' then the Activerecord will not be what we have just tried to set it to

If .DataSource.ActiveRecord intSourceRecord Then
TerminateMerge = True
' the record exists
Else

.DataSource.FirstRecord = intSourceRecord
.DataSource.LastRecord = intSourceRecord
.Destination = wdSendToPrinter
.Execute
intSourceRecord = intSourceRecord + 1
End If
Loop
End With
End Sub

d. Perform the merge to an output file and print each section in turn - you
would need to change this if you have more than one section in your mail
merge main document.

Sub PrintEachSection()
Dim iSectionCount As Integer
For iSectionCount = 1 To ActiveDocument.Sections.Count
ActiveDocument.PrintOut Range:=wdPrintFromTo, From:="s" & iSectionCount,
To:="s" & iSectionCount
Next iSectionCount
End Sub

--
Peter Jamieson

"nobag" wrote in message
...
Hi there,

I'm trying to create a mail merge in word, that produces a 6 page booklet
for every person in the excel list.

I've got the data and the booklets exactly as I want them, but I have a
problem when it comes to printing them.

My printer (Panasonic DP6010) has a stapler function on it, and I want it
to
staple each booklet for me. But when I merge to printer it prints all 30
booklets and staples them once.

I assume this is because the mail merge results are being sent as 1
document, not 30 seperate documents.

Is there a way round this?

Thanks for any help




Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Split a mail merge document into individual documents leedelee Mailmerge 29 April 10th 23 08:29 PM
Mail merge only creates first label when doing edit individual lab Scott H Mailmerge 1 January 19th 05 12:59 PM
My printer prints all documents about 25% of actual size John M Page Layout 1 January 14th 05 09:10 PM
Sending Merged Documents to Printer Individually [email protected] Mailmerge 1 December 19th 04 11:50 AM
Merge multiple documents? George M. Lutz New Users 1 November 27th 04 02:06 PM


All times are GMT +1. The time now is 07:54 PM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"