View Single Post
 
Old 04-03-2016, 05:09 AM
JennEx JennEx is offline Windows XP Office 2013
Competent Performer
 
Join Date: May 2010
Posts: 162
JennEx is on a distinguished road
Default

So, unfortunately this last suggestion still resulted in the command failed error.

In an attempt to troubleshoot, I broke apart the
Code:
.OpenDataSource Name:=StrSrc, AddToRecentFiles:=False, LinkToSource:=False, ConfirmConversions:=False, _
                     ReadOnly:=True, Format:=wdOpenFormatAuto ,  Connection:="Provider=Microsoft.ACE.OLEDB.12.0;" & _
                    "User ID=Admin;Data Source=" & StrSrc & ";Mode=Read;Extended Properties=""HDR=YES;IMEX=1;"";", _
                    SQLStatement:=StrSQL, SQLStatement1:="", SubType:=wdMergeSubTypeAccess
                .Execute Pause:=False
I first encountered the command failed error with the piece highlighted in red.

Up until then, the select table dialogue allowed me to select CORE as the datasource. The report populated (maybe prematurely) as it pumped out a page of 135 calculation errors. (ouch!). None of the mailmerge fields in the header or footer populated. But ... one problem a time!
Reply With Quote