Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
MS-Word automation example : From VB to VFP
Message
From
04/02/2004 08:02:14
 
 
To
04/02/2004 07:51:28
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00873797
Message ID:
00873820
Views:
17
Thanks so much, Daniel, it worked perfectly!

Regards,

Fernando

PS. Please see my message to Dorin and Borislav, perhaps you faced the same problem I'm reporting there.

>Fernando,
>
>I couldn't get the WordBasic method to work without changing the default printer. However, the following should work:
>
>
>
>#DEFINE wdDialogFilePrintSetup 97
>
>oWord = CreateObject("Word.Application")
>
>WITH oWord.application.Dialogs(wdDialogFilePrintSetup)
>	.Printer="HP LaserJet 4 on LPT2"
>	.DoNotSetAsSysDefault = .t.
>	.execute
>ENDWITH
>
>HTH
>
>>Hi,
>>
>>I've got instructions to select in what printer MS-Word will execute its next printout in KB #216026 (ActivePrinter Property in Word Sets System Default Printer) as:
>>
>>Set oWord = CreateObject("Word.Application")
>>
>>oWord.WordBasic.FilePrintSetup Printer:="HP LaserJet 4 on LPT2", _
>>      DoNotSetAsSysDefault:=1
>>
>>
>>How should I code in VFP the oWord.WordBasic.FilePrintSetup... statement?
>>
>>Thanks,
>>
>>Fernando
Previous
Reply
Map
View

Click here to load this message in the networking platform