Label Merge Code Possible

D

DbMstr

Is it possible to write code for Publisher that will interact with the
user a bit and then do a mail merge?

I need to merge print 80 labels per sheet with sequential numbers. I
wish to have a MsgBox pop up that knows what the last number from a
previous session was. Asks the user for the number of pages (80 label
pages) to print and then Publisher completes the mail merge to a
specific printer, Dialogue asks user if printing completed and then
retains the last number used in that session to display as the starting
point for a new session.

I have a Publisher template and a SS backend that does this now but
wish to see if I can do it all automatically in Publisher since the
only change is the starting number.

Any chance??

DbMstr
 
D

DbMstr

Ed said:
I'm guessing you know how to write the interaction code, and just need
to work out how to do the merge code.

Have you read AJ May's series of Publisher technical articles?
http://msdn2.microsoft.com/en-us/library/bb191021(office.11).aspx

Thanks Ed, no I hadn't read those articles.
My question was, could I do everything within Publisher rather than an
interaction to an external Db? Yes I can easily do this by creating an
Access or SQL application or having Publisher look to Excel for the
data but couldn't find any information about whether I can create some
sort of Publisher Dialogue to run the numbered label process.
Dennis
 
E

Ed Bennett

DbMstr said:
Thanks Ed, no I hadn't read those articles.
My question was, could I do everything within Publisher rather than an
interaction to an external Db? Yes I can easily do this by creating an
Access or SQL application or having Publisher look to Excel for the
data but couldn't find any information about whether I can create some
sort of Publisher Dialogue to run the numbered label process.

To run an actual mail merge, you'll have to interact with some sort of
external data. An alternative would be to construct the publication
entirely programmatically, but that would prevent multiple different
records per sheet.
 
D

DbMstr

Ed said:
To run an actual mail merge, you'll have to interact with some sort of
external data. An alternative would be to construct the publication
entirely programmatically, but that would prevent multiple different
records per sheet.

So Ed, it sounds like I will be better off just writing an Access
REPORT app to manage the choices I want for number of label pages
desired and what the begining sequential label number should be on the
first label. No problem doing this for me.

It is just that Publisher does such a good job of providing a single
lable design layout for resulting multiple 80 label pages that I have
been using it for this project. I had hoped that I could program
Publisher when open the file, create a user input for number of pages,
display last printed number and suggest or accept a new starting number
from the user and then print away and ask for completion confirmation
to save the last number used.

I have experienced some layout difficulty using these very small labels
in the past in Access reports. Mostly overcame them but lots of wasted
time when there is so little space to work on a perfect repeatable 80
label page in Access.

Thanks for your help
Dennis
 
E

Ed Bennett

DbMstr said:
It is just that Publisher does such a good job of providing a single
lable design layout for resulting multiple 80 label pages that I have
been using it for this project. I had hoped that I could program
Publisher when open the file, create a user input for number of pages,
display last printed number and suggest or accept a new starting number
from the user and then print away and ask for completion confirmation
to save the last number used.

I don't see why you wouldn't be able to automate Excel to create a
spreadsheet in %temp% with the desired set of numbers on. Either
automating both Publisher and Excel from a VB application or automating
Excel from Publisher. Or you could even just construct a list of numbers
in VBA, save it as a text file, and merge from that.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top