I have code gathered from the web for an extension for SSMS. Was fine up until some (braking?) change from SSMS 18.2 to SSMS 19.+. Asking here in hope to hear from someone having faced/conquered the same problem; in hope for a "quick win".
For now, I don't want to expand on 'code level details' 'cos it would be quite lenghty. If need be, I will provide details; I could also post it on GitHub.
SSMS is built on the same UI than VS (Visual Studio). But the way to make it work for SSMS is undocumented. I've found only one sample of a project that would provide UI integration and access to code panes in SSMS. It was made clear it would compile to successfull .vsix only in VS 2017. It does compile on VS19 or VS22 but crashes more or less dramatically while intalled and run within SSMS 19+.
I've managed to have an alternate version of the same code, that does not interact with code panes working in SSMS 19+, compiled VS2022. The process to make it work was so intense in trial and errors with packages and versions I end up not quite sure of the steps I took to get there. But it shows it can be done. But so far, not quite for what I need : acces to active code pane.
Tried all the juggling of dlls and packages versions around, but not even close and defenitely no cigar !!!.
All the packages visible in NuGet Management are at version 15. Version 17 is available and offered as an update but beware ! Way back then it was called "DLL HELL"; have we come up with something like "NuGet NoGet" for the present time ? No matter you call it, its hard to find to right dll for an undocumented integration.
Was hoping to find some renamed namespaces, within which I would have located the missing classes and all. But NO.
Since I'm very frustrated wasting time on the integration instead of on spending time on functionnality, I would welcome any generous soul offering a "Here's how I do it" fully fonctional project on VS2022 for a .vsix extension for SSMS 19+