>Hi,
>I would like to have one-to-many relationship table for mailmerge doc. As I know, MS Word doesnt provide diurect way to do this. I got to use DATABASE field code for this. I search thru internet, and found some sample code to accomplish it via merge field using MS Access database. I amend the merge field to VFP database. However, MS Word keeps complaining that unable to open data source. Pls advise.
>
>{DATABASE \d "C:\\data1.dbc " \c "Driver={Microsoft Visual FoxPro Driver};UID=;PWD=;SourceDB=c:\data1.dbc;SourceType=DBC;Exclusive=No;BackgroundFetch=Yes;Collate=Machine;Null=Yes;Deleted=Yes;" \s "SELECT * FROM orders where cnoee = '{ MERGEFIELD cnoee }'" \l "4" \b "447" \h}
>
>Thank you
Similar to the creation of reports in VFP, I would think it is easier to create a single table first. In VFP, you can do this with one or more SELECT - SQL commands. Then, copy the file to a dBASE III file (type foxplus), to make it accesible for Word.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)