MartyConnelly
martyconnelly at shaw.ca
Sat Jan 20 19:05:53 CST 2007
You could try just before the line Set objWord = Nothing objWord.quit Beach Access Software wrote: >Bryan: > >I agree with you. But Access disagrees with us. Here's the code: > >Private Sub cmdDisplayWordDoc_Click() > >Dim objWord As Word.Application >Dim objWordDoc As Word.Document > >Set objWord = New Word.Application > >With objWord > 'Visible is set True in order to view the operation. > .Visible = True > .Documents.Open (Me.fldFABWorkInstructions) >End With > >Set objWord = Nothing > >End Sub > >I run it with the task manager open to processes and as it goes through the >code WINWORD opens up and the document is displayed. I put a breakpoint at >End Sub just to satisfy myself that the code passed through the Set objWord >= Nothing. > >WINWORD disappears from the task managers' processes screen but the document >is still open. > >Go figure... > >Rocky Smolin >Beach Access Software >858-259-4334 >www.e-z-mrp.com > >-----Original Message----- >From: accessd-bounces at databaseadvisors.com >[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Bryan Carbonnell >Sent: Saturday, January 20, 2007 6:56 AM >To: Access Developers discussion and problem solving >Subject: Re: [AccessD] Closing Word > >On 1/17/07, Beach Access Software <bchacc at san.rr.com> wrote: > > >>Never mind. I think. Adding Set objWord = Nothing at the end of the >>routine seems to work. It leaves the document open and there's no WINWORD >>left in the task manager's processes. >> >> > >Sorry, just catching up, but.... > >No Winword in Task manager, but the Word doc is still open? >Impossible. (now that I say that someone is going to prove me wrong) > >Winword is Word. Without it, being present you won't have the document open. > >can you elaborate a bit more? I'm curious. > > > -- Marty Connelly Victoria, B.C. Canada