View Single Post
  #11   Report Post  
Don Petersen via OfficeKB.com
 
Posts: n/a
Default

Hi,
Thanks for the response. I looked at the KB article again. It suggests
lowering security. Don't think I want to do that. I get the prompt when I
open the doc manually, but not from VB. The datasource is getting opened. I
get the correct info, just the wrong format (Letters vs Catalog).

I tried both your code fragments and neither was successful at changing the
MainDocumentType from FormLetters to Catalog / Directory

I opened the doc manually and got:
Debug.Print ActiveDocument.MailMerge.DataSource.Name
E:\mii\ipdb\pluto\IPdb.mdb
Debug.Print ActiveDocument.MailMerge.DataSource.ConnectString
DSN=MS Access Database;DBQ=E:\mii\ipdb\pluto\IPdb.mdb;DriverId=2 5;FIL=MS
Access;MaxBufferSize=2048;PageTimeout=5;
Debug.Print ActiveDocument.MailMerge.DataSource.QueryString
SELECT * FROM `Docs` WHERE ((`Class` = 'All') AND (`Type` = 'US'))
Debug.Print ActiveDocument.MailMerge.MainDocumentType
3 (wdCatalog / wdDirectory)

This all looks pretty good to me. Any other ideas? Thanks.

--
Message posted via http://www.officekb.com