Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.mailmerge.fields
HD
 
Posts: n/a
Default Still having problem with merging with DBF files

Hi there,

I was having problem merging a Word file with a DBF file. After many hours
and a few messages to this newsgroup, I installed VFPODBC.msi, which
installed itself in the System DSN tab of the ODBC Administrator... I
finally found out that the drivers needed to be installed in the User DSN...
which is what I did... I added them in the User DSN tab using exactly the
same names and
driver... and now the merge between Word and DBF works... almost...
the merge works only with DBF files that do NOT have memo fields... As soon
as my DBF file has a memo field, I'm back where I started again... it gives
me a message : "Word was unable to open the data source".

Anybody has any idea as to why it does that??... I REALLY would appreciate
the input.

H. Dumas


  #2   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Peter Jamieson
 
Posts: n/a
Default Still having problem with merging with DBF files

I don't know whether you will be able to see the memo fields in a merge, but
I do think you should read through what I said last time (I have repeated it
below) partly because of the possibility that the FoxPro driver is actually
the wrong one
for your .dbf - in other words, there may need to be a change to the Win2003
server.

Peter Jamieson

I think there are two main possible problems he
a. you may only be able to connect programmatically and
b. you may actually need to use the Access/Jet driver (which typically
works for older .dbf format files, whereas the FoxPro driver is for more
recent FoxPro formats), and since it isn't installed by default in the
version of the MDAC (data access) that comes with Win 2003 you may have to
install it.

I would try the following.

If you have Excel, see if you can open the DBF in Excel using the FoxPro
driver. If you cannot, you almost certainly need to install the Jet stuff
that used to be part of the MDAC. You can probably find the right version
for Win 2003 at

by following the "Product and Update Downloads" link at

http://msdn.microsoft.com/data/downloads/default.aspx

If you can open the DBF in Excel, it suggests that Word ought to be able

to
use the FoxPro driver. I would proceeed as follows:

Follow the instructions in this Knowledgebase article:

"Opening This Will Run the Following SQL Command" Message When You Open a
Word Document"

at

http://support.microsoft.com?kbid=825765

See if that makes any difference on its own (I doubt it, but it's worth a
try)

Then, if possible, try opening the data source in VBA code using the

FoxPro
driver. An example of the syntax you need for a .dbf with a FoxPro ODBC
User/System DSN is

ActiveDocument.MailMerge.OpenDataSource _
Name:="", _
Connection:="DSN=Visual FoxPro Tables;SourceType=DBF;" & _
"SourceDB=c:\fp;Deleted=No;Exclusive=No;", _
SQLStatement:="SELECT * FROM 'mytable'", _
Subtype:=wdMergeSubTypeWord2000

where "Visual FoxPro Tables" is the name of the ODBC DSN, c:\fp is the
folder containing the .dbf, and the .dbf is called mytable.dbf. You may
need backquotes ` instead of straight quotes ' around the table name.


That's my best guess, anyway.

Peter Jamieson




"HD" wrote in message
...
Hi there,

I was having problem merging a Word file with a DBF file. After many
hours
and a few messages to this newsgroup, I installed VFPODBC.msi, which
installed itself in the System DSN tab of the ODBC Administrator... I
finally found out that the drivers needed to be installed in the User
DSN...
which is what I did... I added them in the User DSN tab using exactly the
same names and
driver... and now the merge between Word and DBF works... almost...
the merge works only with DBF files that do NOT have memo fields... As
soon
as my DBF file has a memo field, I'm back where I started again... it
gives
me a message : "Word was unable to open the data source".

Anybody has any idea as to why it does that??... I REALLY would appreciate
the input.

H. Dumas




Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Merging to multiple files? Lise Microsoft Word Help 10 July 12th 07 09:24 PM
Problem in mail merging in word 2003 with XP as OS and VB 6 VJ Mailmerge 1 January 14th 06 09:18 AM
Help with merging 1 address to many files FL Consultant Mailmerge 8 July 23rd 05 12:25 PM
How do I convert MS Word Office 2000 files to PDF files? alfa Microsoft Word Help 4 June 21st 05 08:33 AM
Duplicate Files John Flatley New Users 1 December 22nd 04 09:17 AM


All times are GMT +1. The time now is 01:28 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"