SSMS 2008 add-ins: one problem solved
I can't add any useful comment on the changes made in assemblies between versions, because I didn't attempt writing an SSMS add-in until I'd already upgraded to 2008. However, I did encounter one problem right away when I attempted to write an SSMS version of a VS 2010 add-in, as have others. The boilerplate code in the OnConnect method, which was generated by VS, would fail on this line:
The error message was “No such interface supported”.
A little poking about, and it became clear that this is because, well, the host application isn't a DTE2 anymore. It's a SSMS object with a very long name and no obvious connection to the DTE2. Which is a problem if you need any of the DTE2's properties, as you probably do.
But the fix is easy. The addInInst object has a DTE property that is, in fact, of type DTE2! So all you have to do to get over this speed bump is to change those two assignment statements:
And carry on from there.