Closing Instance of Word

J

Jeff Freilich

Hi All

I am using Access 2000

I am using the following code to open a Word document, extract some
information to populate into my access database and then close
document - my issue is that it seems to be keeping an instance of Word
open every time (Word is not actually open but if you go to task
manager it shows all of the open Word processes)

How can I kill the instance of word once I am done with it - I thgouth
setting appword= Nothing would do that - any suggestions?

Thanks,

Jeff

Dim appWord As Word.Application
Dim OL As Word.Document

Set appWord = New Word.Application
Set OL = appWord.Documents.Open(Me.txtOLFileName.Value) 'Change the
path and file name as required.
ImportA '(This is the Procedure I use to extract infrormation - I can
provide if needed)
OL.Close wdDoNotSaveChanges
Set OL = Nothing
Set appWord = Nothing
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top