Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Creating mail merge application using Word

Guest
Mar 22, 2007 Mar 22, 2007
Hi,

We are in the process in developing a coldfusion web application that enables user to upload Word document and a data source for mail merge.

After spending few hours googling, we are still unable to find a definite solution. Does anyone give us a pointer on how we might be able to achieve this? Can coldfusion maybe by using Java be able to access Microsoft's Office objects?

Your help will be truly appreciated.
TOPICS
Advanced techniques
1.6K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Deleted User
Mar 23, 2007 Mar 23, 2007
Use the <cfobject> tag of coldfusion to create the below objects of word application (you should have Microsoft word installed in your cf server).
Word.Application
Word.Document
Word.MailMerge

Then you can follow the same steps how you do a VB program to create the Word MailMerge in ColdFusion. A sample vb code is give below,

Dim oWordApp As New Word.Application
Dim WrdDoc As Word.Document
Dim wrdMailMerge As Word.MailMerge

Set WrdDoc = oWordApp.Documents.Open("template path", ReadOnly:=True)...
Translate
Guest
Mar 23, 2007 Mar 23, 2007
Use the <cfobject> tag of coldfusion to create the below objects of word application (you should have Microsoft word installed in your cf server).
Word.Application
Word.Document
Word.MailMerge

Then you can follow the same steps how you do a VB program to create the Word MailMerge in ColdFusion. A sample vb code is give below,

Dim oWordApp As New Word.Application
Dim WrdDoc As Word.Document
Dim wrdMailMerge As Word.MailMerge

Set WrdDoc = oWordApp.Documents.Open("template path", ReadOnly:=True)
Set wrdMailMerge = WrdDoc.MailMerge
wrdMailMerge.OpenDataSource Name:="file path", Format:="format", ConfirmConversions:=True
wrdMailMerge.Destination = wdSendToNewDocument
wrdMailMerge.Execute
oWordApp.ActiveDocument.SaveAs FileName:="full path & name", FileFormat:="format"

Set oWordApp = Nothing
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Mar 25, 2007 Mar 25, 2007
LATEST
Thanks for your help, I will try to implement your suggestion.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources