Hello Jason For us, this usually happens when you close a session that's not open. Typically this happens because an I/O step fails in a way that causes the session to close. I think, but I'm not sure, that in some cases UniObjects does not throw an error. Or, it could be that we're catching the error and not re-throwing it if it's an unexpected condition.
I think there is a property on the session you can test, I believe it's .IsActive. (I'm answering this from home, so I'm going from memory.) But in any case, find the code where this error is being thrown, and check to see if the session object is still valid when it tries to close Hope this helps Victor St. Clair -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Friday, September 29, 2006 3:37 PM To: u2-users@listserver.u2ug.org Subject: [U2] UniObject.Net error Hi all. I started doing some testing on UniObject .Net and Visual Basic 2005. Everything in my program works fine except I get the following run-time error upon exiting the program: ------------------------------------------------------------------- System.Exception was unhandled Message="Safe handle has been closed Source: System Method: System.Net.Sockets.SocketError shutdown(System.Net.SafeCloseSocket, Int32) at System.Net.UnsafeNclNativeMethods.OSSOCK.shutdown(SafeCloseSocket socketHandle, Int32 how)\r\n at System.Net.Sockets.Socket.Shutdown(SocketShutdown how)\r\n at IBMU2.UODOTNET.UniRPCConnection.Close()\r\n at IBMU2.UODOTNET.UniSession.Disconnect()\r\n at IBMU2.UODOTNET.UniObjects.CloseSession(UniSession us)" Source="UODOTNET" StackTrace: at IBMU2.UODOTNET.UniObjects.CloseSession(UniSession us) at IBMU2.UODOTNET.UniSession.Finalize() ------------------------------------------------------------------- This error can not be trapped using VB's try-catch statement so I suspect it's a run-time issue between UniObject and .Net Framework 2.0 which is used by Visual Studio 2005. Does anyone know if there are compatibility issues between UniObject .Net and .Net 2.0 Framework? And is there a solution resolve the issue? Thanks. Jason ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/