none
VSIX navigation in solution RRS feed

  • Question

  • Hello,

    I want to navigate between includes of the my ProjectItem. I know how to get the include name itself, however I can't find out how do I or if it's possible to navigate between Include elements, a.k.a Ctrl+Shift+G inside the Visual Studio IDE.

    Here is the example how I get the the includes:

    VCFileCodeModel fileCodeModel = projectItem.FileCodeModel as VCFileCodeModel;
    CodeElements codeElements = fileCodeModel.Includes;

    Thanks,

    Thursday, June 27, 2019 2:55 PM

All replies

  • Hi Nikolay,

    Welcome to MSDN forum.

    I'm afraid the answer is negative, according to the document there is no this kind of Interface we can implement and switch between the Includes. For now it only supports AddIncludes but not something like NavigateIncludes.

    In addition: It is supported to navigate to one position by MoveToLineAndOffset interface like what described in this issue.  Maybe you can try if we can achieve that goal use the interface like MoveToLineAndOffset with the StartPoint of CodeElement. 

    Hope it helps.

    Best Regards

    Lance


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, June 28, 2019 4:03 AM
  • So, how does visual studio does this? I mean you can do it in IDE or it is not available for the developer?
    Wednesday, July 3, 2019 7:42 AM
  • Hi Nikolay,

    The Visual Studio SDK helps us extend some new features like this:

    1. Add commands, buttons, menus, and other UI elements to the IDE
    2. Add tool windows for new functionality
    3. Extend IntelliSense for a given language, or provide IntelliSense for new programming languages
    4. Use light bulbs to provide hints and suggestions that help developers write better code
    5. Enable support for a new language
    6. Add a custom project type

    But it doesn't mean we can extend every part of it, some features for now is not supported by VS SDK. So I'm afraid the answer would be negative and in my opinion it's not available for developers.

    Any feedback would be expected.

    Best Regards

    Lance


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Thursday, July 4, 2019 2:19 AM