Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Winword decoding
Message
From
05/04/2000 12:39:29
 
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00355719
Message ID:
00355758
Views:
18
Hi Nick,
I have but just one problem with the code you sent me. When I run it I get
a OLE ErrorCode of 0x80020005: Type Mismatch. Not sure what is going on...
Also do you know a place to look up OLE Error codes. Thanks Eric


>In general you just write the parameters in VFP style,, so False corresponds to .f., instead of Wod constants you can substitute their values from VBA Help or, better use the Word constants header file which you can download from Files Section.
>
>So this sample coul be translated to:
>
>#INCLUDE w97const.h
>oWord.ActiveDocument.MailMerge.OpenDataSource ("F:\APPS\MERGEDATA.DBF",.f.,.f.,.t.,.f.,"","","","",.f.,wdOpenFormatAuto, ;
>"DSN=FoxPro Files - Word;UID=;PWD=;SourceDB=F:\APPS;SourceType=DBF;Exclusive=No;BackgroundFetch=Yes;Collate=MACHINE;Null=Yes;Deleted=Yes;","SELECT * FROM MERGEDATA","")
>
>oWord.Application.MailingLabel.DefaultPrintBarCode = .f.
>
>oWord.Application.MailingLabel.CreateNewDocument("","","ToolsCreateLabels1",wdPrinterManualFeed)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform