Creating addin for studio 2008
I'm trying to create a simple c# addin for visual studio. I've been following the guidelines dotted around th开发者_如何学Goe net, and it says to put my main code in a routine called 'Exec'.
However, I cannot find this routine anywhere. I'm assuming there should be a stub for this. All I have is a connect.cs, with Onconnection, OnDisconnection, OnAddinsUpdate, OnStartUpComplete, OnBeginShutDown.
All I want to do is open one form with a button.
Thank you guys. Chris.
Yes you should have the exec method that looks like so:
public void Exec(string commandName, EnvDTE.vsCommandExecOption executeOption, ref object varIn, ref object varOut, ref bool handled) { handled = //your method here for eg. return; }
As far as i remember correctly this method comes from some interface or abstract COM class that connection inherited but i'm not sure as i'm not on the VS2005/2008 ATM.
Try adding the method yourself.
精彩评论