Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
other
informationbridge
office.intranets
office.misc
office.setup
office.xml
officeupdate
onenote
photodraw.discussion
powerpoint
producer
proj.standard&server
project
project.developer
project.pro_and_serve
project.server
project.vba
project2000
publisher
publisher.prepress
publisher.programming
publisher.webdesign
visio
visio.createshapes
visio.database.modeling
visio.dev.diagrams
visio.dev.shapesheet
visio.dev.vba
visio.dev.vc
visio.developer
visio.general
visio.installation
visio.printing
visio.software.modeling
visio.troubleshoot
  
 
date: Wed, 25 Jun 2008 13:58:04 -0700,    group: microsoft.public.publisher.programming        back       


Newbie trying to Programmatically mail merge from Access to Publis   
Forgive me if this is the wrong forum, I am a newbie.  I have an access 
database that contains the mege data that I would like to use in publisher.  
I have created a form in Access with a button that on execute I would like to 
use Office Automation and open my Publisher Template and merge the data 
fields.  From access I have included the reference to the Publisher object.  
I can include the code that I have so far but I am not even sure I am on the 
right path.  Haven't been able to find any examples on programmatically doing 
publisher's mail merge.  Any help or push in the right direction is 
appreciated.
date: Wed, 25 Jun 2008 13:58:04 -0700   author:   qbutler

Re: Newbie trying to Programmatically mail merge from Access to Publis   
qbutler wrote:
> Haven't been able to find any examples on programmatically doing 
> publisher's mail merge.  Any help or push in the right direction is 
> appreciated.

AJ May has a series of technical articles about Publisher 
programmability at 
http://msdn.microsoft.com/en-us/library/bb191021(office.11).aspx

Two of these cover Publisher's merge features.

-- 
Ed Bennett - MVP Microsoft Publisher
http://ed.mvps.org
date: Thu, 26 Jun 2008 10:41:00 +0100   author:   Ed Bennett

Re: Newbie trying to Programmatically mail merge from Access to Pu   
"Ed Bennett" wrote:

> qbutler wrote:
> > Haven't been able to find any examples on programmatically doing 
> > publisher's mail merge.  Any help or push in the right direction is 
> > appreciated.
> 
> AJ May has a series of technical articles about Publisher 
> programmability at 
> http://msdn.microsoft.com/en-us/library/bb191021(office.11).aspx
> 
> Two of these cover Publisher's merge features.
> 
> -- 
> Ed Bennett - MVP Microsoft Publisher
> http://ed.mvps.org
> 
Thanks, I will start with this and see if I can transfer the same logic into 
access.  I want to be able to complet the mail merge from withing access with 
a button on a form and let it open up Publisher throught automation.  
Thanks
date: Mon, 30 Jun 2008 08:40:02 -0700   author:   qbutler

Re: Newbie trying to Programmatically mail merge from Access to Pu   
qbutler wrote:
> Thanks, I will start with this and see if I can transfer the same logic into 
> access.  I want to be able to complet the mail merge from withing access with 
> a button on a form and let it open up Publisher throught automation.  

This is relatively simple to do. You need to set a reference to the 
Publisher object library, and then create a new instance of Publisher with:

Dim pApp As New Publisher.Application.

Then instead of using ThisDocument, either create or open a document and 
assign it an object.

Dim aDoc As New Publisher.Document
Set aDoc = pApp.Open(...)

(The syntax for the .Open method is documented in the Publisher Object 
Model Help; available on MSDN or by pressing F1 in Publisher's VBA IDE.)

-- 
Ed Bennett - MVP Microsoft Publisher
http://ed.mvps.org
date: Tue, 01 Jul 2008 00:53:26 +0100   author:   Ed Bennett

Re: Newbie trying to Programmatically mail merge from Access to Pu   
Thanks Ed, 

I think I'm on my way.  I appreciate the help!

"Ed Bennett" wrote:

> qbutler wrote:
> > Thanks, I will start with this and see if I can transfer the same logic into 
> > access.  I want to be able to complet the mail merge from withing access with 
> > a button on a form and let it open up Publisher throught automation.  
> 
> This is relatively simple to do. You need to set a reference to the 
> Publisher object library, and then create a new instance of Publisher with:
> 
> Dim pApp As New Publisher.Application.
> 
> Then instead of using ThisDocument, either create or open a document and 
> assign it an object.
> 
> Dim aDoc As New Publisher.Document
> Set aDoc = pApp.Open(...)
> 
> (The syntax for the .Open method is documented in the Publisher Object 
> Model Help; available on MSDN or by pressing F1 in Publisher's VBA IDE.)
> 
> -- 
> Ed Bennett - MVP Microsoft Publisher
> http://ed.mvps.org
>
date: Wed, 2 Jul 2008 08:44:03 -0700   author:   qbutler

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us