locked
MailMerge in Microsoft Word RRS feed

  • Question

  • User-1731144759 posted

    Is there anyway to create a MailMerged Word document in ASP.Net without having to install Microsoft word on the production server?  I found a way to create it using

    Microsoft.Office.Interop.Word

    and it works great on my machine but when I move it to production I get this error

    Retrieving the COM class factory for component with CLSID {000209FF-0000-0000-C000-000000000046} failed due to the following error: 80040154

    Tuesday, April 7, 2009 2:02 PM

Answers

  • User-1630302068 posted

     basically you go to http://openxmldeveloper.org/default.aspx and grab the libraries there.  Remember that mail merge is really just microsoft marketing speak for using a word document as an output template.  So conceptually the process goes read a record from the db, load the data into the word document, repeat.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, April 7, 2009 4:00 PM

All replies

  • User2130758966 posted

    As far as I know the alternative to installing Office on a server is to purchase a commercial component.

    Yeah looking in this thread its not even recommended to install on Office on a server because it can be unstable:

     

    Tuesday, April 7, 2009 3:16 PM
  • User-1630302068 posted

    Can you use the new office 2007 or old office xml document file formats?  If so mail merge is pretty easy to implement manually. 

    Tuesday, April 7, 2009 3:34 PM
  • User-1731144759 posted

    Yes I could use either, how would I go about implementing it manually?  And just to be sure I don't need to install office on the server do I?

    Tuesday, April 7, 2009 3:45 PM
  • User-1630302068 posted

     basically you go to http://openxmldeveloper.org/default.aspx and grab the libraries there.  Remember that mail merge is really just microsoft marketing speak for using a word document as an output template.  So conceptually the process goes read a record from the db, load the data into the word document, repeat.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, April 7, 2009 4:00 PM
  • User-1731144759 posted

    Yeah but if a user wants to print labels how is that going to be affected.  Word will not be able to read it record by record will it?

    Tuesday, April 7, 2009 4:06 PM