Search code examples
buildvisual-studio-2017hotkeys

Why does F7 no longer build my project in VS2017 if the code editor window is active?


I changed my hotkey configurations under Tools/Options/Environment/Keyboard to Visual C++ 6, so that the build command is now mapped to F7. However, the key doesn't work while the code editor window is active. If I click on the solution explorer or the Error List window I can use F7 just fine.

Ctrl+Shift+B still works, no matter which window is active, and if I choose a different key mapping, even F6 or Shift+F8 work everywhere as well. Only F7 doesn't work while the code editor is active.

I use Visual Studio Community 2017 and until recently I was able to use F7 just fine, no matter which window was active. Did a recent update cause that bug?


Solution

  • Visual Studio v15.7.0 added the ToggleRazorView F7 shortcut. You can Remove it in keyboard options:

    enter image description here