Visual Studio: Show active file in solution explorer

One of the most annoying thing about Visual Studio default settings is the fact that the Solution Explorer doesn't track what files you are currently looking at. Alot of developers thought this was the only way, and had to bear the pain of flicking through the Solution Explorer while scratching their head to figure out 'where the hell I put this file?'.

Some have found a work around by using Visual Studio plugin like VS File Finder and Resharper (Ctrl + Shift + T / Resharper_GoToFile). While others found right clicking on the tab - open containing folder to be helpful enough.

There is actually a setting in Visual Studio that does this automatically.

Tools - Options - Projects and Solutions - Track Active Item in Solution Explorer

Just tick the box..and you're all set!

  1. says:

    nice! didn't know that

  2. says:

    Yeah, a very handy thing to know

  3. says:

    I thought that was the default mate?

    Either way it's worhty to note that if you're working on a slow pc you gain some performance by turning it off (not that I would)

  4. ronaldwidha says:

    @Xian worthy to note that if you're on a slow machine, ... you might want to get a better machine. LOL

  5. says:

    Thanks.. I stumbled on your post while scratching my head for last half an hour how to turn this feature on!

  6. says:

    Thanks a lot. I really appreciate it. Your tip helped me to get rid of one of the most annoying things in VS.

  7. says:

    I think alot of time are spent by devs looking for files. This tip and Resharper will increase productivity significantly for any .Net devs

  8. says:

    thanks a lot..

  9. Gman says:

    yeah, it seemed to be default for mine but somehow switched itself off randomly, so thanks for the post, now I have switched it back on!

  10. PSU Kardi says:

    Thank you so much!

  11. Rajmca05 says:

    Thanks a lot!!! It helped me a lot...

  12. James says:

    In the event you want to only track the current file through a keyboard shortcut - the activity is "View.TrackActivityinSolutionExplorer" (assign keys here -> Tools - Options - Environment - Keyboard)

  13. Ssrmit62 says:

    thanks a lot.. It saved my time a lot.

  14. Ray661 says:

    Thanks this will save me a lot time in future!!!

  15. Sam says:

    Thanks dude!

  16. PratikChandra says:

    This feature is actually annoying for me most of the time...so I don't want to enable/disable the global vs settings, but just like in resharper(I guess), I'd like to track/locate JUST the current file in the solution-explorer, through a shortcut. Is there a way to do that or any alternate tweak or something??? It would really help, and ofcourse save a lot of time too!!!

  17. abc says:

    make sure this feature is disabled initially and then use the shortcut twice every-time you use it. You can assign some single-press handy shortcut like "ctrl+shift+D". It will track the current file and then immediately disable tracking, so the solution explorer will not keep jumping to the active file when you navigate through your other opened files. Hope it helps. :-)

  18. PratikChandra says:

    https://dvanderboom.wordpress.com/2008/03/21/visual-studio-macro-track-item-in-solution-explorer-on-demand/#comment-459

  19. Bruno Cassol says:

    Thnx!

  20. Courtney Mills says:

    Thanks, I was looking for this functionality.

  21. lorinc says:

    Thanks for the  info, it's really useful!

  22. Truls Unstad says:

    Thank you very much, just what I was looking for. This was driving me mad.

  23. Rolando says:

    Fantastic! thanks for this info, Ive been looking for this for months

  24. skyfire163 says:

    Thank you!

  25. Cody says:

    Holy cow. I've been searching through solution explorer for months (usually use the >of shortcut to open files, but that's not enough). You just saved me so much time.

  26. Srinivas says:

    Thanks for the tip, this is really helpful to many people in our team.

  27. Amit Stefen says:

    Excellent... I installed the fresh copy of VS2010 and it never included this setting by default. Thanks Ronald

  28. Horsin'Around says:

    Thanks!  I was looking for that!

  29. Donald Herman says:

    thanks OP!!!

  30. steve says:

    Thanks

  31. Maxim says:

    Thank you!!

  32. Phil Gardocki says:

    Thanks again for this ever so useful post. For reasons I can't explain about every 6 months or so, this setting goes unchecked for me and I have to find it again. Different machines, companies, versions of VS. They all lose it once in a while.

  33. ronaldwidha says:

    glad that you find it useful. For me, it's this post to set up beyond compare with VS https://www.ronaldwidha.net/2008/11/26/the-best-comparison-tool-and-vs2008-integration/ - VS2008, VS2010, VS2012 across Vista, 7, 8 DP, CP, RP, RTM ... I have to do it again again and again. It's nice to have a cheat sheat like these.

  34. Ioan Antoniu says:

    thanks!

  35. charlie the cat says:

    puurrrrrrfect!

  36. Ankit says:

    Great tip. Thank you

  37. Ant says:

    Thank you soooooo much! You've just saved my sanity!

  38. Florian says:

    Resharper: Shift + Alt + L

  39. B2#5!#%@$1jfB2$1 says:

    Awesome.

  40. Sara says:

    I love you because of this guidance!!!!!!!!!!