Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
General Field - Word Doc print
Message
From
12/07/2001 11:01:15
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Title:
General Field - Word Doc print
Miscellaneous
Thread ID:
00529734
Message ID:
00529734
Views:
37
I need to print a general field containing a Word object which is
contained on a form. Word2000, VFP 6.

When I double click the container class, Word instantiates no probs.
However, printing is disabled. How on earth do I get it to print?

I have tried various things like the following...

frmDummy = CREATEOBJECT("Form")
frmDummy.ADDOBJECT("olbConent","OleBoundControl")
thisform.olbContent.ControlSource = "correspond.content"
thisForm.olbContent.DoVerb(1) &&starts an instance of Word
* thisForm.olbContent.Fileprint
objWordInst = createOBJECT("Word.Basic") &&create a reference to Word
** set paper size - see Q121049 referenced above
objWordInst.olbContent.FilePageSetup(,,"1","1",,"1","1","8.5 in","11
in")
* objWordInst.Insert("Brown Shoes Don't Make It")
objWordInst.AppHide
objWordInst.FilePrint
WAIT WINDOW "Printing document" TIMEOUT 5
objWordInst.AppClose
RELEASE objWordInst


with no joy.

I expect it is something simple, but it is eluding me. Any good
examples out there somewhere?

TIA
On a CLEAR day you can see forever.
Next
Reply
Map
View

Click here to load this message in the networking platform