HOWTO: Using a FoxPro Database in a Word for Windows Print Merge
ID: Q92966
|
The information in this article applies to:
-
Microsoft Visual FoxPro for Windows, versions 3.0, 5.0, 6.0
-
Microsoft FoxPro for MS-DOS, versions 1.0, 1.01, 1.02, 2.0, 2.5x, 2.6x
-
Microsoft FoxPro for Windows, versions 2.5x, 2.6x
-
Microsoft Word for Windows, versions 1.0, 1.1, 1.1a, 2.0, 6.0
Information from a Microsoft FoxPro database file can be converted for
use in the print merge feature of Microsoft Word versions 1.x, 2.0, and
6.0 for Windows.
NOTE: Memo fields convert as blank fields. If the data in the memo field is
required for the print merge, you must write a program to convert the data.
Only Word versions 1.x and 2.x for Windows require that memo fields be
converted.
Word Version 1.x
To convert a FoxPro database for use with a print merge in Word version 1.x
for Windows, issue the following commands in the FoxPro Command window:
USE <database>
COPY TO <newfilename> TYPE DELIMITED
Here <database> is the name of the existing database and
<newfilename> is the name of the intermediate format file. FoxPro
automatically appends the .DBF extension to the filename.
Word Version 2.0
To convert a FoxPro database for use with a print merge in Word version 2.0
for Windows, issue the following commands in the FoxPro Command window:
USE <database>
COPY TO <newfilename> TYPE FOXPLUS
where <database> is the name of the existing database and
<newfilename> is the name of the intermediate format file. FoxPro
automatically appends the .DBF extension to the filename.
Word Version 6.0
In Word version 6.0, you can use ODBC to directly read in the FoxPro
database.
NOTE: See Q157767 for information on downloading the ODBC driver for Visual
FoxPro.
- Start Word version 6.0.
- From the Tools menu, choose Mail Merge. Then choose the Create
button under Main Document. Edit your main document as needed.
- From the Tools menu, choose Mail Merge, choose the Get Data button under
Data Source, and then choose Open Data Source.
- Select "MS FoxPro Files (*.DBF)" from the List Files Of Type box, and
then select the FoxPro database.
NOTE: If "MS FoxPro Files (*.DBF)" is not available, you must install
the data access (ODBC) utilities using the Word Setup program.
REFERENCES
For additional information, please see the following article in the
Microsoft Knowledge Base:
Q157767 PATCH: Vfpodbc5.exe Visual FoxPro ODBC Driver Version 5.0
Additional query words:
kbvfp300 kbvfp500 kbvfp600 kbodbc
Keywords : kbVFp FoxDos FoxWin FxinteropOdbc
Version : 1.0 1.01 1.02 2.0 2.5x 2.6x 3.0
Platform : MS-DOS WINDOWS
Issue type : kbhowto
Last Reviewed: August 5, 1999