C # Runtime Exception

I am working on a C # program to get users from a component called Cyber-Ark that stores encrypted data. When my code runs halfway, I get this exception, and even if I catch all the exceptions that still get it. Is there any work for this?

Unhandled Exception: System.Runtime.InteropServices.InvalidComObjectException: COM object that has been separated from its underlying RCW cannot be used.
   at System.StubHelpers.StubHelpers.GetCOMIPFromRCW(Object objSrc, IntPtr pCPCMD, Boolean& pfNeedsRelease)
   at PAObjectsLib.PrivateArkClass.Term()
   at CyberArk.API.Objects.PrivateArk.Term()
   at CyberArk.API.Objects.PrivateArk.DoDispose(Boolean disposing)
   at CyberArk.API.Objects.CyberArkBase.Dispose()
   at Program.Main(String[] args)
+3
source share
3 answers

, COM ( IUnknown.Release). , , RCW (, ) , COM "" COM-, .

, Dispose .

+5

" ?"

.

, Visual Studio , , (catch). debug/Exception, .

0

There are several reasons that may throw an exception. (try disposing correctly, as @Martin Liversage said).

If it does not work, and you purchased this component, contact Cyber-Ark Technical Support.

0
source

Source: https://habr.com/ru/post/1780667/


All Articles