Is there a Visual Studi开发者_高级运维o shortcut to highlight the current file in Solution Explorer?
You can enable this option to always highlight the current (active) file:
Tools -> Options -> Projects and Solutions -> Track Active Item in Solution Explorer
To my knowledge there's no shortcut to go to it directly, however you could bind your own key combination by going to Tools -> Options -> Environment -> Keyboard
, search for View.TrackActivityInSolutionExplorer
then assign a shortcut to it. The downside to this approach is that it toggles the option on and off rather than perform a one time highlight of the active file.
Alternately, you can use a macro to accomplish what you originally asked about. This blog post provides such a macro: Visual Studio Macro: Locate Item in Solution Explorer on Demand.
Tools – Options – Projects and Solutions – Track Active Item in Solution Explorer
the option for auto-sync is:
Tools|Options|Projects and Solutions|General|Track Active Item in Solution Explorer
this will give an outline of the class or file you are currently working on
You can use Resharper:
Shift + Alt + L
精彩评论