Rank: Advanced Member Groups: Member
Joined: 12/23/2013 Posts: 114
|
Hi, I sometimes get crash reports from my users with the following exception/stack trace: Detach must be called in the same thread as Attach
Code: C#
at EO.Internal.rivx.amyk()
at EO.WebBrowser.WebView.sbgk(Boolean fo)
at EO.WebBrowser.WebView.Destroy()
at EO.WebBrowser.WebView.sbkn(epgu lk, jfom ll)
at EO.Internal.epgu.hhig(rjav e, IntPtr f, Int32 g, IntPtr h, IntPtr i, Boolean& j)
at EO.Internal.rjav.amyq(IntPtr rrv, Int32 rrw, IntPtr rrx, IntPtr rry, Boolean& rrz)
at EO.Internal.rjav.oflb(IntPtr odp, Int32 odq, IntPtr odr, IntPtr ods, Boolean& odt)
at EO.Internal.rjav.ofla(IntPtr odl, Int32 odm, IntPtr odn, IntPtr odo)
at Interop.User32.DispatchMessageW(MSG& msg)
at System.Windows.Forms.Application.ComponentManager.Interop.Mso.IMsoComponentManager.FPushMessageLoop(UIntPtr dwComponentID, msoloop uReason, Void* pvLoopData)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(msoloop reason, ApplicationContext context)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(msoloop reason, ApplicationContext context)
at System.Windows.Forms.Application.Run(Form mainForm)
I triple checked my code and can't really find any interaction with the WebView which is not happening from the UI thread. From what I can see, this mostly happens when my application is closed and when I close/destroy multiple web views. Any idea how to find out what's going on? Regards, Stefan
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,217
|
Hi,
This might be a bug that we have just fixed. Please download build 23.1.25 from our download page and see if it resolves the issue for you.
Thanks!
|
Rank: Advanced Member Groups: Member
Joined: 12/23/2013 Posts: 114
|
Will do, thank you!
|
Rank: Newbie Groups: Member
Joined: 9/16/2015 Posts: 6
|
I updated to 23.1.25 on my WinForms app to try resolve this, but everytime I close the MDI parent with a web control visible in an open MDI child, I'm seeing:
System.InvalidOperationException HResult=0x80131509 Message=Detach must be called in the same thread as Attach. Source=EO.Base StackTrace: at EO.Internal.pxpk.uqcf()
It does not happen if I close an MDI child and keep the MDI parent open. Anyway, I found this stops the issue from happening for me:
private void MdiParent_FormClosing(object sender, FormClosingEventArgs e) { Application.DoEvents(); ... }
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,217
|
Hi, Can you try to isolate the problem into a small test project and send the test project to us? See here for more details: https://www.essentialobjects.com/forum/test_project.aspxOnce we have the test project we will look into it immediately. Thanks!
|