CefSharp upgrade and getting unhandled exception Cannot pass a GCHandle across AppDomains #4720
Closed
Dileepreddyj
started this conversation in
General
Replies: 1 comment
-
Please keep discussions contained within a single thread. Closing as duplicate of #4719 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I apologize for reposting this discussion; I lacked the means to reopen #4719, as I still perceive the matter as unresolved.
We have been utilizing CefSharp version 71 for approximately four years and recently made the decision to upgrade to version 120. While implementing the required modifications (only replaced version dlls and dependant cefsharp files. No code level changes), we encountered an unhandled exception during the initialization of Cef (Cef.Initialize), specifically stating 'Cannot pass a GCHandle across AppDomains.' Despite having come across articles in the past discussing the same 'Cannot pass a GCHandle across AppDomains' exception with CefSharp, we have not yet found a suitable solution.
Adding the in-depth error for reference:
System.ArgumentException
HResult=0x80070057
Message=Cannot pass a GCHandle across AppDomains.
Parameter name: handle
Source=mscorlib
StackTrace:
at System.Runtime.InteropServices.GCHandle.InternalCheckDomain(IntPtr handle)
at System.Runtime.InteropServices.GCHandle.FromIntPtr(IntPtr value)
at gcroot<System::Collections::Generic::IEnumerable<CefSharp::CefCustomScheme ^> ^>..P$AAU?$IEnumerable@P$AAVCefCustomScheme@CefSharp@@@Generic@Collections@System@@(gcroot<System::Collections::Generic::IEnumerable<CefSharp::CefCustomScheme ^> ^>* )
at CefSharp.Internals.CefSharpApp.OnContextInitialized(CefSharpApp* )
Beta Was this translation helpful? Give feedback.
All reactions