How to program a mailmarge from Access 2007
Posted on 2010-09-04
I have created an application in Access 2007 which has forms, reports, modules, etc... The data is in an .mdb file.
I want to put a button in a form that, when clicked, generate a mailmerge based on an SQL query which has a parameter (related to the record selected on the actual form).
When I try to execute my code, it keeps locked on the call to mailMerge.OpenDataSource because word is asking which connection method I want to use (OLE-DB, ODBC, etc...).
I want to avoid these word messages. Is that possible ? Can you provide me a code example for doing this MailMerge ?