ACC: Importing Word Print Merge Data Files to Microsoft Access

ID: Q96899


The information in this article applies to:


SUMMARY

Novice: Requires knowledge of the user interface on single-user computers.

This article describes how to import data from a Microsoft Word for Windows print merge data file for use in Microsoft Access.


MORE INFORMATION

In order to use data from a Word for Windows print merge data file in Microsoft Access, the file must be saved as a comma- or tab-delimited unformatted text file.

Word for Windows can perform print merges on data contained in files that are comma- or tab-delimited, or on data formatted from a table. If the data is already comma- or tab-delimited, you must take care to ensure that the file is saved as an unformatted text file.

If the data is in table form, the table must first be converted to a tab-delimited format before saving it as a text file.

NOTE: In Word for Windows, you can create multiple-line information within a table cell that contains carriage returns (paragraph marks). The carriage returns must be removed before converting the table to a tab-delimited format.

Converting Data from a Table to a Tab-Delimited Format

Word for Windows 1.x:
  1. Open the data document in Word for Windows.


  2. Position the insertion point anywhere inside the table.


  3. Press ALT+Keypad 5 to select the entire table (make sure that NUM LOCK is turned off).


  4. From the Insert menu, choose Table To Text.


  5. In the Convert Table To box, select Tab Delimited, and then choose OK.


Word for Windows 2.x:
  1. Open the data document in Word for Windows.


  2. Position the insertion point anywhere inside the table.


  3. From the Table menu, choose Select (or press ALT+Keypad 5).


  4. From the Table menu, choose Convert Table To Text.


  5. Choose the Tabs button from the Separate Text With group, and then choose OK.


Word for Windows 6.0, 7.0 and 97:
  1. Open the data document in Word for Windows.


  2. Position the insertion point anywhere inside the table.


  3. On the Table menu, click Select Table (or press ALT+Keypad 5).


  4. On the Table menu, click Convert Table To Text.


  5. Click the Tabs button in the Convert Table to Text dialog box and then click OK.


Saving the Data File as an Unformatted Text-Only File

Word for Windows 1.x:
  1. From the File menu, choose Save As, and enter an unique file name in the Save File Name box.


  2. Choose the Options button.


  3. From the File Format box, select Text Only, and choose OK.


Word for Windows 2.x and 6.0:
  1. From the File menu, choose Save As, and type a unique file name in the File Name box.


  2. In the Save File As Type box in the lower left corner, select Text Only, and choose OK.


Word 7.0:
  1. On the File menu, click Save As, and type a unique file name in the File Name box.


  2. In the Save File As box in the lower-left corner, select Text Only, and click Save.


Word 97:
  1. On the File menu, click Save As, and type a unique file name in the File Name box.


  2. In the Save As Type box in the lower-left corner, select Text Only, and click Save.


Removing Unwanted Carriage Returns from a Table-Formatted Data File

Word for Windows 1.x:
  1. In the Search For box type "^p" (the caret symbol (^) is generated by pressing SHIFT+6).


  2. In the Replace With box press SPACEBAR once.


  3. Clear the Confirm Changes check box and choose the OK button.


Word for Windows 2.x, 6.0, 7.0 and 97:
  1. On the Edit menu, click Replace.


  2. In the Find What box, type "^p" (the caret symbol (^) is generated by pressing SHIFT+6).


  3. In the Replace With box, press SPACEBAR once.


  4. Click Replace All.


Importing the Text Data File into Microsoft Access 1.0, 1.1 and 2.0


  1. From the File menu, choose Import.


  2. Select Text (Delimited) from the Data Source list and choose OK.


  3. Select the Word for Windows text file to import from the file list and choose the Import button.


  4. Select First Row Contains Field Names if the first row in the Word data file contains a list of field names.


  5. Choose the Options button.


  6. Choose {tab} in the Field Separator box.


  7. Choose the OK button to begin the import.


Importing the Text Data File into Microsoft Access 7.0 and 97


  1. On the File menu, point to Get External Data, and then click Import.


  2. In the Files Of Type box, select Text Files.


  3. Select the Word for Windows text file to import, and click Import.


  4. Select the Delimited option in the Text Import Wizard, and then click Next.


  5. Select Tab for the Delimiter and click to select the "First Row Contains Field Names" check box if the first row in the Word data file contains a list of field names.


  6. Select {none} in the Text Qualifier box, and then click Finish to complete the import.


Additional query words: winword


Keywords          : kbinterop IntpOff 
Version           : WINDOWS:1.0,1.1,1.1a,2.0,2.0a,2.0a-CD,2.0b,2.0c,6.0,6.0a,6.0c,7.0,97
Platform          : WINDOWS 
Issue type        : kbhowto 

Last Reviewed: March 21, 1999