Repository: PowerToys
Issue: PowerToys Preview crash: The object invoked has disconnected from its clients. (0x80010108) 
Labels: Issue-Bug,Product-File Explorer,Needs-Triage

### Microsoft PowerToys version

0.81.1

### Installation method

Microsoft Store

### Running as admin

Yes

### Area(s) with issue?

File Explorer: Preview Pane, PowerToys Run

### Steps to reproduce

Just click on any file in file explorer.
Open PTRun and hover mouse over elements

### ✔️ Expected Behavior

Working PTPreview and PTRun

### ❌ Actual Behavior

Screenshots related to PTRun: 
![2024-06(June)-19_22;03;21--PowerToys PowerLauncher](https://github.com/microsoft/PowerToys/assets/61331405/1c663927-caa8-4035-a10c-416d142ec90c)
![image](https://github.com/microsoft/PowerToys/assets/61331405/80539c4c-6466-4fa3-852e-f92affeb21a9)

Screenshots related to PTPreview: 

![2024-06(June)-19_22;03;15--explorer](https://github.com/microsoft/PowerToys/assets/61331405/ffd9d41d-69fa-40c8-b67d-9f17fbd6796b)
![2024-06(June)-19_22;03;07--PowerToys MonacoPreviewHandler](https://github.com/microsoft/PowerToys/assets/61331405/a8c8460e-3b75-4683-80d7-33d0c8f115b7)

Here's bugreport ZIP:
[PowerToysReport_2024-06-19-22-02-48.zip](https://github.com/user-attachments/files/15905119/PowerToysReport_2024-06-19-22-02-48.zip)

Here's full trace:
```
See the end of this message for details on invoking 
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.Runtime.InteropServices.COMException (0x80010108): The object invoked has disconnected from its clients. (0x80010108 (RPC_E_DISCONNECTED))
   at System.Runtime.InteropServices.Marshal.ThrowExceptionForHR(Int32 errorCode)
   at Microsoft.Web.WebView2.Core.CoreWebView2Environment.CreateCoreWebView2ControllerAsync(IntPtr ParentWindow)
   at Microsoft.Web.WebView2.WinForms.WebView2.InitCoreWebView2Async(CoreWebView2Environment environment, CoreWebView2ControllerOptions controllerOptions)
   at Microsoft.PowerToys.PreviewHandler.Monaco.MonacoPreviewHandlerControl.<>c__DisplayClass13_0`1.<<DoPreview>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__128_0(Object state)
   at InvokeStub_SendOrPostCallback.Invoke(Object, Span`1)
   at System.Reflection.MethodBaseInvoker.InvokeWithOneArg(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)


************** Loaded Assemblies **************
System.Private.CoreLib
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Private.CoreLib.dll
----------------------------------------
PowerToys.MonacoPreviewHandler
    Assembly Version: 0.81.1.0
    Location: C:\Program Files\PowerToys\PowerToys.MonacoPreviewHandler.dll
----------------------------------------
System.Runtime
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Runtime.dll
----------------------------------------
WinRT.Runtime
    Assembly Version: 2.0.0.0
    Location: C:\Program Files\PowerToys\WinRT.Runtime.dll
----------------------------------------
System.Collections
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Collections.dll
----------------------------------------
System.Collections.Concurrent
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Collections.Concurrent.dll
----------------------------------------
System.Threading
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Threading.dll
----------------------------------------
System.Drawing.Primitives
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Drawing.Primitives.dll
----------------------------------------
PowerToys.ManagedCommon
    Assembly Version: 0.81.1.0
    Location: C:\Program Files\PowerToys\PowerToys.ManagedCommon.dll
----------------------------------------
System.Windows.Forms
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Windows.Forms.dll
----------------------------------------
PowerToys.PreviewHandlerCommon
    Assembly Version: 0.81.1.0
    Location: C:\Program Files\PowerToys\PowerToys.PreviewHandlerCommon.dll
----------------------------------------
System.ComponentModel.Primitives
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.ComponentModel.Primitives.dll
----------------------------------------
System.Windows.Forms.Primitives
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Windows.Forms.Primitives.dll
----------------------------------------
System.Collections.Specialized
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Collections.Specialized.dll
----------------------------------------
PowerToys.Interop
    Assembly Version: 0.81.1.0
    Location: C:\Program Files\PowerToys\PowerToys.Interop.dll
----------------------------------------
System.Runtime.Extensions
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Runtime.Extensions.dll
----------------------------------------
System.Runtime.InteropServices
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Runtime.InteropServices.dll
----------------------------------------
System.Collections.NonGeneric
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Collections.NonGeneric.dll
----------------------------------------
WindowsBase
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\WindowsBase.dll
----------------------------------------
PowerToys.Common.UI
    Assembly Version: 0.81.1.0
    Location: C:\Program Files\PowerToys\PowerToys.Common.UI.dll
----------------------------------------
System.IO.Abstractions
    Assembly Version: 17.0.0.0
    Location: C:\Program Files\PowerToys\System.IO.Abstractions.dll
----------------------------------------
System.Security.AccessControl
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Security.AccessControl.dll
----------------------------------------
System.Diagnostics.TraceSource
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Diagnostics.TraceSource.dll
----------------------------------------
System.Diagnostics.TextWriterTraceListener
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Diagnostics.TextWriterTraceListener.dll
----------------------------------------
System.Diagnostics.FileVersionInfo
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Diagnostics.FileVersionInfo.dll
----------------------------------------
System.Drawing.Common
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Drawing.Common.dll
----------------------------------------
Microsoft.Win32.Primitives
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\Microsoft.Win32.Primitives.dll
----------------------------------------
System.ComponentModel.EventBasedAsync
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.ComponentModel.EventBasedAsync.dll
----------------------------------------
System.Threading.Thread
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Threading.Thread.dll
----------------------------------------
Accessibility
    Assembly Version: 4.0.0.0
    Location: C:\Program Files\PowerToys\Accessibility.dll
----------------------------------------
Microsoft.Win32.SystemEvents
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\Microsoft.Win32.SystemEvents.dll
----------------------------------------
System.Memory
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Memory.dll
----------------------------------------
System.Diagnostics.StackTrace
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Diagnostics.StackTrace.dll
----------------------------------------
System.Text.Encoding.Extensions
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Text.Encoding.Extensions.dll
----------------------------------------
ControlzEx
    Assembly Version: 6.0.0.0
    Location: C:\Program Files\PowerToys\ControlzEx.dll
----------------------------------------
PresentationCore
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\PresentationCore.dll
----------------------------------------
PresentationFramework
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\PresentationFramework.dll
----------------------------------------
DirectWriteForwarder
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\DirectWriteForwarder.dll
----------------------------------------
System.Diagnostics.Debug
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Diagnostics.Debug.dll
----------------------------------------
System.Runtime.CompilerServices.VisualC
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Runtime.CompilerServices.VisualC.dll
----------------------------------------
System.ObjectModel
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.ObjectModel.dll
----------------------------------------
Microsoft.Win32.Registry
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\Microsoft.Win32.Registry.dll
----------------------------------------
System.ComponentModel.TypeConverter
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.ComponentModel.TypeConverter.dll
----------------------------------------
System.ComponentModel
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.ComponentModel.dll
----------------------------------------
System.Xaml
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Xaml.dll
----------------------------------------
System.Private.Uri
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Private.Uri.dll
----------------------------------------
System.Configuration.ConfigurationManager
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Configuration.ConfigurationManager.dll
----------------------------------------
System.Xml.ReaderWriter
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Xml.ReaderWriter.dll
----------------------------------------
System.Private.Xml
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Private.Xml.dll
----------------------------------------
System.Net.WebClient
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Net.WebClient.dll
----------------------------------------
System.Linq
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Linq.dll
----------------------------------------
PresentationFramework-SystemXml
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\PresentationFramework-SystemXml.dll
----------------------------------------
Microsoft.Web.WebView2.Core
    Assembly Version: 1.0.2365.46
    Location: C:\Program Files\PowerToys\Microsoft.Web.WebView2.Core.dll
----------------------------------------
mscorlib
    Assembly Version: 4.0.0.0
    Location: C:\Program Files\PowerToys\mscorlib.dll
----------------------------------------
Microsoft.Web.WebView2.WinForms
    Assembly Version: 1.0.2365.46
    Location: C:\Program Files\PowerToys\Microsoft.Web.WebView2.WinForms.dll
----------------------------------------
System.Runtime.CompilerServices.Unsafe
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Runtime.CompilerServices.Unsafe.dll
----------------------------------------
System.Numerics.Vectors
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Numerics.Vectors.dll
----------------------------------------
System.Drawing
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Drawing.dll
----------------------------------------
PowerToys.Settings.UI.Lib
    Assembly Version: 0.81.1.0
    Location: C:\Program Files\PowerToys\PowerToys.Settings.UI.Lib.dll
----------------------------------------
System.Security.Principal.Windows
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Security.Principal.Windows.dll
----------------------------------------
System.Security.Claims
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Security.Claims.dll
----------------------------------------
System.Text.Json
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Text.Json.dll
----------------------------------------
System.Text.Encodings.Web
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Text.Encodings.Web.dll
----------------------------------------
System.Runtime.Intrinsics
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Runtime.Intrinsics.dll
----------------------------------------
System.Reflection.Emit.Lightweight
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Reflection.Emit.Lightweight.dll
----------------------------------------
System.Reflection.Primitives
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Reflection.Primitives.dll
----------------------------------------
System.Reflection.Emit.ILGeneration
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Reflection.Emit.ILGeneration.dll
----------------------------------------
PowerToys.ManagedTelemetry
    Assembly Version: 0.81.1.0
    Location: C:\Program Files\PowerToys\PowerToys.ManagedTelemetry.dll
----------------------------------------
System.Diagnostics.Tracing
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Diagnostics.Tracing.dll
----------------------------------------
PowerToys.FilePreviewCommon
    Assembly Version: 0.81.1.0
    Location: C:\Program Files\PowerToys\PowerToys.FilePreviewCommon.dll
----------------------------------------
UtfUnknown
    Assembly Version: 2.0.0.0
    Location: C:\Program Files\PowerToys\UtfUnknown.dll
----------------------------------------
System.Text.Encoding.CodePages
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Text.Encoding.CodePages.dll
----------------------------------------
System
    Assembly Version: 4.0.0.0
    Location: C:\Program Files\PowerToys\System.dll
----------------------------------------
System.Threading.ThreadPool
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Threading.ThreadPool.dll
----------------------------------------
System.Threading.Tasks
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Threading.Tasks.dll
----------------------------------------
System.Runtime.Loader
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Runtime.Loader.dll
----------------------------------------
System.Reflection.Metadata
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Reflection.Metadata.dll
----------------------------------------
System.Collections.Immutable
    Assembly Version: 8.0.0.0
    Location: C:\Program Files\PowerToys\System.Collections.Immutable.dll
----------------------------------------

************** JIT Debugging **************
```





### Other Software

_No response_