Skip to content

[Question] Can I combine use DynamicVisibility and BeforeQueryStatus ? #194

Closed

Description

@phuocle

I can use the <CommandFlag>DynamicVisibility</CommandFlag> that show/hide the popup window code menu with the extension .cs and .vb correctly. (Thanks @madskristensen for the sample)

But on the popup, I want to use: BeforeQueryStatus because I want to check the current position in the class and class should inherit by an interface

My old code working fine with BeforeQueryStatus (and sure I don't use DynamicVisibility)
It used ProvideAutoLoad that I don't want to use, it make my extension take time to load.

Any help or sample with the combine DynamicVisibility and BeforeQueryStatus wil be great. Tried a lot of cases but not success.

Thanks.

PS: On the way convert all existing code to Community.VisualStudio.Toolkit, great lib.

Activity

  1. madskristensen commented on Nov 2, 2021

    @madskristensen
    Contributor

    You can only use BeforeQueryStatus once your package has been loaded. So if you need to use it, you should set the ProvideAutoload attribute on your package class

  2. locked and limited conversation to collaborators on Nov 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions