Re: ODBC problem with Microsoft Word and Excel
От | david.paulo |
---|---|
Тема | Re: ODBC problem with Microsoft Word and Excel |
Дата | |
Msg-id | 1444196827343-5869049.post@n5.nabble.com обсуждение исходный текст |
Ответ на | ODBC problem with Microsoft Word and Excel ("Karl Denninger" <karl@denninger.net>) |
Список | pgsql-odbc |
Here is what I needed to do 1) Use ANSI odbc driver - this is key - Unicode does not work - I am using version 9.03.04.00. In this example the name of the odbc DSN is LFData. It has a username and password embedded in it. 2) It may not be needed for word merge (I am also doing separate queries) but I registered Microsoft ActiveX Data Objects 6.1 Library from the VBA Tools menu 3) Within the macro that performs the merge I have the following (xcfPax is a view that provides the fields for the merge): SQLRequest = "select * from xcfPax where matterno = '" & matterRef & "'" Doc.MailMerge.MainDocumentType = wdFormLetters Doc.MailMerge.Destination = wdSendToNewDocument Doc.MailMerge.OpenDataSource _ Name:="", _ SQLStatement:=SQLRequest, _ AddToRecentFiles:=False, _ Connection:="DSN=LFData", _ SubType:=wdMergeSubTypeWord2000 ' Execute the mail merge. Doc.MailMerge.Execute Doc.MailMerge.DataSource.Close -- View this message in context: http://postgresql.nabble.com/ODBC-problem-with-Microsoft-Word-and-Excel-tp2189996p5869049.html Sent from the PostgreSQL - odbc mailing list archive at Nabble.com.
В списке pgsql-odbc по дате отправления: