Mail Merge

suka

New Member
Hello,

I am looking at using Mailmerge with Word and the data source as a text file which is comma (,) separated for the various fields. Is there any method by which we can change the delimiter instead of comma to any other character. I'm using code like
DEFINE VARIABLE chWordAppl AS COM-HANDLE NO-UNDO.
DEFINE VARIABLE chmaildoc AS COM-HANDLE NO-UNDO.
DEFINE VARIABLE chdoc AS COM-HANDLE NO-UNDO.

CREATE "Word.Application":U chWordAppl NO-ERROR.
chdoc = chWordAppl:Documents:OPEN("C:\wrk\abc.doc").
chmaildoc = chdoc:Mailmerge.
chmaildoc:OpenDatasource("C:\wrk\file1.txt").
chmaildoc:EXECUTE().
chdoc:CLOSE(NO).

I would like to know if there is any method or property to set the delimiter for the text file to any other character.
Thanks.

Regards,
Suchitra
Origin Info Tech (India) Ltd
 
Top