• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 402
  • Last Modified:

Microsoft 2010 Publisher E-mail Merge

I created a microsoft office 2010 email merge document and I can not figure out how to keep the subject line when I click finish and merge. I have tried putting in the information I want in the subject line then sending the emails but when I close the document and open it again select finish and merge the subject field is blank again
0
natevelli
Asked:
natevelli
1 Solution
 
xtermieCommented:
You can perform the mail merge FROM outlook, which is the easiest and provide a common subject line...read here for step by step instructions
http://www.groovypost.com/howto/microsoft/send-personalized-mass-emails-outlook-2010/

If you want to do it from Publisher, there is a VBA solution to your issue, found here
http://help.lockergnome.com/office/Mail-Merge-Subject-Line--ftopict1017247.html

Basically it says that:
f you are familiar with VBA, you can use Word's MailMerge events and
VBA to specify the subject for each email.
e.g. in the VBA Editor, Insert a new Class Module, name it
EventClassModule, and insert the following code:

Public WithEvents App As Word.Application
Private Sub App_MailMergeBeforeRecordMerge( _
ByVal Doc As Document, _
Cancel As Boolean)
' set this to be the exact name
' of the field you want to use
' (uppercase/lowercase are
' significant here)
Const strSubjectFieldName = "mysubjectfield"
Doc.MailMerge.MailSubject = _
Doc.MailMerge.DataSource.DataFields(strSubjectFieldName).Value
End Sub

In an ordinary module, put the following VBA
'---
Dim x As New EventClassModule
Sub MergeWithEvents()
EnableEventHandler
' Do the merge
ActiveDocument.MailMerge.Execute Pause:=False
' The events fire for all documents
' so disable them
DisableEventHandler
End Sub

Sub EnableEventHandler()
Set x.App = Word.Application
End Sub

Sub DisableEventHandler()
Set x.App = Nothing
End Sub
'---
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now