Skip to content


VS 2008 : Plugin Pop-up issue

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

While adding a pop-up to a plugin, designed in VS 2008, one of the commonly faced problem is:

Error 1 The best overloaded method match for ‘EnvDTE80.Commands2.AddNamedCommand2(EnvDTE.AddIn, string, string, string, bool, object, ref System.Array, int, int, EnvDTE80.vsCommandControlType)’ has some invalid arguments C:Punit GanshaniDesktop ApplicationsMyAddin2MyAddin2Connect.cs 40 24 MyAddin2
Error 2 Argument ’7′: cannot convert from ‘ref object[]‘ to ‘ref System.Array’ C:Punit GanshaniDesktop ApplicationsMyAddin2MyAddin2Connect.cs 40 140 MyAddin2

Resolution:

Change:
object []contextGUIDS = new object[] { };
to:
System.Array
contextGUIDS = new object[] { };

and it should compile & execute perfectly.


Related Posts:

Posted in C#, Microsoft .NET, Winform.

Tagged with .


0 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.



Some HTML is OK

or, reply to this post via trackback.