Posted 16 November 2023, 8:05 am EST
See attached sample: open “Form1” in designer, click “Tab 2” and press the DEL key (to delete the tab).
Visual Studio (or the designer process) crashes. Deleting it with the quick actions work.
Attaching another Visual Studio debugger to the “DesignToolsServer.exe” process, I see this exception:
System.NullReferenceException
HResult=0x80004003
Message=Object reference not set to an instance of an object.
Source=C1.Win.Ribbon.6.Design.Server
StackTrace:
at C1.Win.Ribbon.Design.Server.Glyphs.SelectionGlyph.GetHitTest(Point p) in C1.Win.Ribbon.Design.Server.Glyphs\SelectionGlyph.cs:line 319
StackTrace:
C1.Win.Ribbon.6.Design.Server.dll!C1.Win.Ribbon.Design.Server.Glyphs.SelectionGlyph.GetHitTest(System.Drawing.Point p) Line 319 C#
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Designers.Behaviors.BehaviorService.SetActiveGlyph(System.Drawing.Point point) Unknown
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Designers.Behaviors.BehaviorService.Microsoft.DotNet.DesignTools.Designers.IInputDispatcher.OnMouseMove(Microsoft.DotNet.DesignTools.Designers.MouseDispatchEventArgs e) Unknown
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Designers.ScrollableControlDispatcher.OnMouseMove(Microsoft.DotNet.DesignTools.Designers.MouseDispatchEventArgs e) Unknown
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Designers.DesignerFrame.Dispatcher.OnMouseMove(Microsoft.DotNet.DesignTools.Designers.MouseDispatchEventArgs e) Unknown
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Protocol.Endpoints.Input.InputMessageHandler.HandleRequest(Microsoft.DotNet.DesignTools.Protocol.Endpoints.Input.InputMessageRequest request) Unknown
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Protocol.Endpoints.RequestHandler<Microsoft.DotNet.DesignTools.Protocol.Endpoints.Input.InputMessageRequest, Microsoft.DotNet.DesignTools.Protocol.Endpoints.Input.InputMessageResponse>.Microsoft.DotNet.DesignTools.Protocol.Endpoints.IRequestHandler.HandleRequest(Microsoft.DotNet.DesignTools.Protocol.Endpoints.Request request) Unknown
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Protocol.Endpoints.RequestManager.HandleRequestAsync(string name, Microsoft.DotNet.DesignTools.Protocol.Endpoints.Request request) Unknown
[Resuming Async Method]
System.Private.CoreLib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state) Line 183 C#
System.Private.CoreLib.dll!System.Runtime.CompilerServices.AsyncTaskMethodBuilder<Microsoft.DotNet.DesignTools.Protocol.Endpoints.Response>.AsyncStateMachineBox<Microsoft.DotNet.DesignTools.Protocol.Endpoints.RequestManager.<HandleRequestAsync>d__10>.MoveNext(System.Threading.Thread threadPoolThread) Line 324 C#
System.Windows.Forms.dll!System.Windows.Forms.Control.InvokeMarshaledCallbackHelper(object obj) Unknown
System.Private.CoreLib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state) Line 183 C#
System.Windows.Forms.dll!System.Windows.Forms.Control.InvokeMarshaledCallbacks() Unknown
System.Windows.Forms.dll!System.Windows.Forms.Control.WndProc(ref System.Windows.Forms.Message m) Unknown
System.Windows.Forms.dll!System.Windows.Forms.ScrollableControl.WndProc(ref System.Windows.Forms.Message m) Unknown
System.Windows.Forms.dll!System.Windows.Forms.Form.WndProc(ref System.Windows.Forms.Message m) Unknown
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Server.Window.ServerWindow.WndProc(ref System.Windows.Forms.Message m) Unknown
System.Windows.Forms.dll!System.Windows.Forms.Control.ControlNativeWindow.WndProc(ref System.Windows.Forms.Message m) Unknown
System.Windows.Forms.dll!System.Windows.Forms.NativeWindow.Callback(System.IntPtr hWnd, Interop.User32.WM msg, System.IntPtr wparam, System.IntPtr lparam) Unknown
[Native to Managed Transition]
[Managed to Native Transition]
System.Windows.Forms.dll!System.Windows.Forms.Application.ComponentManager.Interop.Mso.IMsoComponentManager.FPushMessageLoop(System.UIntPtr dwComponentID, Interop.Mso.msoloop uReason, void* pvLoopData) Unknown
System.Windows.Forms.dll!System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Interop.Mso.msoloop reason, System.Windows.Forms.ApplicationContext context) Unknown
System.Windows.Forms.dll!System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Interop.Mso.msoloop reason, System.Windows.Forms.ApplicationContext context) Unknown
System.Windows.Forms.dll!System.Windows.Forms.Application.Run(System.Windows.Forms.ApplicationContext context) Unknown
Microsoft.DotNet.DesignTools.Server.dll!Microsoft.DotNet.DesignTools.Server.DesignToolsServer.StartUIThreadAsync.AnonymousMethod__1() Unknown
System.Private.CoreLib.dll!System.Threading.Thread.StartHelper.Callback(object state) Line 42 C#
System.Private.CoreLib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state) Line 183 C#
System.Private.CoreLib.dll!System.Threading.Thread.StartCallback() Line 105 C#
[Async Call Stack]
[Async] StreamJsonRpc.dll!StreamJsonRpc.JsonRpc.DispatchIncomingRequestAsync(StreamJsonRpc.Protocol.JsonRpcRequest request) Unknown
[Async] StreamJsonRpc.dll!StreamJsonRpc.JsonRpc.HandleRpcAsync(StreamJsonRpc.Protocol.JsonRpcMessage rpc) Unknown
Best regards
Wolfgang