Oracle Forms and OLE2, releasing objects

From: Brian Membrey <mouth_at_primus.com.au>
Date: Thu, 05 Aug 1999 09:22:22 GMT
Message-ID: <01bedf22$69d06620$553486cb_at_default>



[Quoted] I've created a form which uses the inbuilt OLE2 package to link to MS Word 97, pass some basic identification data, then print a Medical Analysis (ie just a Word doc with the passed data as identification).

Basically, the form creates the OLE object (as WORD.BASIC), passes data and prints the new document just fine. I then release the object (OLE2.RELEASE_OBJ). This all seemed simple and worked well after debugging until I went to log out (NT4.0 platform), then discovered I had (ahem!) THIRTEEN instances of winword.exe running, all with a "dirty" document requiring response to "do you want to save"!!

Obviously my RELEASE_OBJ does not remove the winword instance.

Q1 should RELEASE_OBJ actually close the application or does it just release any resources associated with the OLE link?

Q2 if I need to physically close winword via an OLE call before the release, how can I do this witout the "do you want to save" dialogue.

Q3 I used WORD.BASIC as the object type because I interfaced Forms and Word quite happily a two or three years ago (ie Word 6) Is there a preferred object type for W.Vord 97 and VBA? In my original Word Basic code, I used EditGoTo and nominated a bookmark to identify the required spot for insertion of passed data ... this no longer seems to work and I have to use cursor positioning (DownPara, WordRight, etc) to navigate!

Q4 DOES ANYONE KNOW WHERE ANY OF THIS IS ACTUALLY DOCUMENTED - I.E EITHER the FORMS SIDE AND/OR THE MS WORD (or whatever) SIDE???

TIA ! Received on Thu Aug 05 1999 - 11:22:22 CEST

Original text of this message