Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Printing Word
Message
From
29/03/2000 10:23:26
 
 
To
29/03/2000 09:41:00
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Title:
Miscellaneous
Thread ID:
00352065
Message ID:
00352102
Views:
16
Hi Tom,
I am by no means a Word OLE guru, but I do have a thought on this

if filecnt > 0
for n = 1 to filecnt
WITH oword
.Documents.Open(print_file)
.ActiveDocument.PrintOut(0,0,range,"",from,to)
.Quit
ENDWITH
delete file (print_file)
endfor
endif

I believe the problem is in the 6th line of code there '.Quit'
This closes the Word application and thusly, there is no way to open a document. I believe all you wanted to do was close that initial document, and instead you're quitting the entire word document. Try just using this

.ActiveWindow.Close

Hope this works for you.
Paul A. Busbey
Victoria Insurance
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform