Tonatiuh
Dec 29th, 1999, 01:59 AM
I'm opening a Word object in two diferent ways but, the Instance of Word is still in memory all time later.
Method 1
Dim objWord As New Word.Application
objWord.Visible = False
objWord.Documents.Open "Document.doc"
objword.Printout
objWord.Documents.Close
Set objWord = Nothing
Method 2
Dim docWord as Object
Set docWord = CreateObject("Word.Basic")
docWord.FileOpen ("document.doc")
docWord.FilePrint
docWord.FileClose
Set docWord = Nothing
I'm using the Word 8 reference. In both cases the Word instance stay on memory. I think the 'Set DocWord = Nothing' is not the correct sentence to close the Word instance.
Any idea will be deeply apreciated.
Thanks!
[This message has been edited by Tonatiuh (edited 12-29-1999).]
Method 1
Dim objWord As New Word.Application
objWord.Visible = False
objWord.Documents.Open "Document.doc"
objword.Printout
objWord.Documents.Close
Set objWord = Nothing
Method 2
Dim docWord as Object
Set docWord = CreateObject("Word.Basic")
docWord.FileOpen ("document.doc")
docWord.FilePrint
docWord.FileClose
Set docWord = Nothing
I'm using the Word 8 reference. In both cases the Word instance stay on memory. I think the 'Set DocWord = Nothing' is not the correct sentence to close the Word instance.
Any idea will be deeply apreciated.
Thanks!
[This message has been edited by Tonatiuh (edited 12-29-1999).]