Home Dashboard Directory Help

Problems with ContextUIGUIDs and vsCommandDisabledFlagsValue in EnvDTE.Commands.AddNamedCommand by Carlos J. Quintero


 as Won't Fix Help for as Won't Fix

Sign in
to vote
Type: Bug
ID: 276732
Opened: 5/11/2007 4:09:52 AM
Access Restriction: Public
User(s) can reproduce this bug


The EnvDTE.Commands.AddNamedCommand method does not honor ContextUIGUIDs and vsCommandDisabledFlagsValue. In fact, it does it in the reverse way. First, see the MSDN docs:


As the documentation states, if the add-in is not loaded, the ContextUIGUIDs and vsCommandDisabledFlagsValue parameters are used to know the state of the command (once loaded, the QueryStatus method will be used instead). If a ContextUIGUIDs is used and it is active, then the command should be enabled. If it is not active, then the command could be disabled or invisible and the programmer can specify it using the vsCommandDisabledFlagsValue. We will see that the AddNamedCommand does not behave as documented.

Sign in to post a comment.
Posted by Microsoft on 5/14/2007 at 5:07 PM
Thanks for reporting this issue. Unfortunately we will not be able to address this issue in Visual Studio codename Orcas due to time constraints.

The Visual Studio IDE Team
Posted by Microsoft on 5/14/2007 at 12:53 AM
Thanks for your feedback. We have reproduced this bug on Visual Studio 2005 SP1, and we are sending this bug to the appropriate group within the VisualStudio Product Team for triage and resolution.

Thank you,
Visual Studio Product Team.
Sign in to post a workaround.