Assuming that you must an object variable that references your MI session then you need to set it to NOTHING. This will release the MI session and close it. You can test for this in VB with If myObject Is Nothing then etc etc
You need to make sure that the object is not still be referenced by another part of your code (e.g. a form or module)because the release/closedown of the MI session only happens when the last reference goes. This is true of any object variable of course. HTH Paul Crisp Syntegra Innovation Place Delta Bank Road Newcastle NE11 9DJ Tel 0191 461 4522 Fax 0191 460 1987 -----Original Message----- From: A.W. Male & Associates Pty Ltd [mailto:[EMAIL PROTECTED] Sent: 16 September 2003 17:03 To: [EMAIL PROTECTED] Subject: MI-L Testing for an open session of MI Hi folks, I have an integrated MI and MS Access routine. I would like to test for the existence of an open session of MI from within Access using VB - reason : If a session of MI is open and I create a new session of MI, I receive an Access error message. I would like to trap the error and warn that MI is already running and should be closed Thanks Alistair --------------------------------------------------------------------- List hosting provided by Directions Magazine | www.directionsmag.com | To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Message number: 8404 ******************************************************************** This email may contain information which is privileged or confidential. If you are not the intended recipient of this email, please notify the sender immediately and delete it without reading, copying, storing, forwarding or disclosing its contents to any other person Thank you Check us out at http://www.syntegra.com ********************************************************************
