WebUtil - MailMerge [message #360258] |
Thu, 20 November 2008 03:53  |
pcardoso
Messages: 1 Registered: November 2008
|
Junior Member |
|
|
Hello All
I have a VB6 project that, among other code, has the following lines:
obj.ActiveDocument.MailMerge.MainDocumentType = wdFormLetters
obj.ActiveDocument.MailMerge.OpenDataSource Name := gsDataSource
obj.ActiveDocument.MailMerge.Execute
Can someone help to translate this 3 lines to calls to WebUtil?
I already have the following:
args := CLIENT_OLE2.CREATE_ARGLIST;
CLIENT_OLE2.ADD_ARG(args, 'somefile.doc');
app := CLIENT_OLE2.CREATE_OBJ('Word.Application');
docs := CLIENT_OLE2.GET_OBJ_PROPERTY(app, 'Documents');
CLIENT_OLE2.INVOKE(docs, 'Open', args);
CLIENT_OLE2.SET_PROPERTY(app,'Visible',1);
ad := CLIENT_OLE2.GET_OBJ_PROPERTY(app, 'ActiveDocument');
Thanks
Pedro Cardoso
|
|
|
|