How to Automatically Use ODBC Rather Than DDE

Last reviewed: February 5, 1998
Article ID: Q105900
The information in this article applies to:
  • Microsoft Word for Windows, versions 6.0, 6.0a, 6.0c

SUMMARY

When you open a database file or attach a data file for a print merge in Word, Word will use DDE by default to gather the information. To automatically use ODBC, follow the directions below.

WORKAROUND #1

WARNING: ANY USE BY YOU OF THE CODE PROVIDED IN THIS ARTICLE IS AT YOUR OWN RISK. Microsoft provides this macro code "as is" without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and/or fitness for a particular purpose.

Select the Confirm Conversions option when you specify which database to use.

  1. From the Tools menu, choose Mail Merge.
2. Select Get Data, Open Data Source. 3. Select Confirm Conversions.

Macros for Method #1

REM Choosing a data file for a Print Merge

Sub MAIN
FileConfirmConversions - 1 Dim dlg As MailMergeHelper GetCurValues dlg On Error Goto bye Dialog dlg MailmergeHelper dlg bye:
End Sub

REM Opening a Database file using FileOpen.
Sub MAIN
FileConfirmConversions - 1 Dim dlg As FileOpen GetCurValues dlg On Error Goto bye Dialog dlg FileOpen dlg bye:
End Sub

WORKAROUND #2

If the database is listed in the [Extensions] section of the WIN.INI file, commenting out or removing the line will force Word to use ODBC to access the database.

Microsoft Access Example

[Extensions] xlw=C:\WINDOWS\WINAPPS\EXCEL\EXCEL.EXE ^.xlw

'MDB=C:\WINDOWS\WINAPPS\ACCESS\msaccess.exe  ^.MDB

NOTE: To comment a line out of the WIN.INI file, insert an apostrophe at the beginning of the line.


KBCategory:
KBSubcategory: kbmerge
Additional query words: 6.0 print merge faster database 6.0a 6.0c
word6 winword dbase access paradox
Keywords : kbmerge kbprint
Version : 6.0 6.0a 6.0c
Platform : WINDOWS
Issue type : kbhowto


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: February 5, 1998
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.