Question about Navigation bar in C#

금은섭 20 Reputation points
2023-08-01T08:34:15.55+00:00

탐색 모음

hello. I have a question because I have an uncomfortable part while using C#.

[Right figure] In MFC coding, only the functions of the active file were displayed on the navigation bar, so it was easy to navigate. [Left figure] In C#, all variables and functions of the project are displayed.

Is there a way to display only the functions of the active file (Form) on the navigation bar?

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,403 questions
{count} votes

Accepted answer
  1. Tianyu Sun-MSFT 24,891 Reputation points Microsoft Vendor
    2023-08-08T09:15:48.8866667+00:00

    Hi @금은섭,

    I tested on VS Pro 2017 15.9.55, either with a newly created project(C#) or with a C# project but have some code added, the results are the same => only the functions of the currently active file are displayed. Everything was set by default as I tested with a newly installed VS 2017 and didn’t change any settings.

    I notice that you are using 15.9.42, could you try to update it to the latest version of VS 2017? Besides, are you using any extensions which may affect the navigation bar? If you have set some configurations in VS, perhaps resetting VS settings(run devenv /ResetSettings in VS Developer Command Prompt) works.

    Best Regards,

    Tianyu


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

2 additional answers

Sort by: Most helpful
  1. 금은섭 20 Reputation points
    2023-08-06T23:49:41.81+00:00

    User's image

    문의 드린 VS 버전은 2017 입니다.

    새로운 프로젝트를 생성해도 C#에서는 전체 프로젝트의 변수와 함수가 함께 출력되고,

    MFC를 2017버전에서 실행하면 현재 활성화된 파일의 함수만 출력됩니다.

    0 comments No comments

  2. 금은섭 20 Reputation points
    2023-08-06T23:58:38.7633333+00:00

    User's image

    Hi, @Tianyu Sun-MSFT

    VS version is 2017.

    And even if you create a new project in C#, functions and variables of the entire project are displayed together in the navigation bar, and only the functions of the currently active file are displayed when C++ (MFC) is executed.

    Should I change something about C#?

    0 comments No comments