Updating to VS 2022 broke my Tool Window (InvalidCastException) #406
Unanswered
mhershberg
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I tried updating a custom extension of mine to VS 2022 and ran into a problem I don't know how to solve. The extension has a tool window, derived from BaseToolWindow. When I try to display it by calling ShowAsync() in response to a menu command the code it throws an exception: "Exception thrown: 'System.InvalidCastException' in mscorlib.dll"
I've followed the examples in the Community Toolkit site and I'm not sure what's wrong. The exception doesn't stop execution of Visual Studio or break into the debugger so I have no idea how to debug this.
I can put a breakpoint on the ShowAsync() call but stepping into or over just resumes execution and logs the exception.
Please help!
Beta Was this translation helpful? Give feedback.
All reactions