Overview

It’s common today to use the CTRL+W in various applications including most web browsers. If you’ve used Visual Studio you’ve probably noticed that this keyboard shortcut does not work when trying to close the currently opened tab.

In this article, I’ll show you how you can easily configure Visual Studio to close the currently opened tab.

Visual Studio Icon

Configuration

Ok, lets get started …

Here’s how you can configure the keyboard shortcut in Visual Studio:

  1. Navigate to TOOLS > OPTIONS > KEYBOARD
  2. Add CTRL+W global shortcut to Window.CloseDocumentWindow
  3. Remove the CTRL+W shortcut for Edit.SelectCurrentWord

Final Thoughts

I hope you’ve found this quick Visual Studio tip to be useful. If you have found alternative ways to configure this, please feel free to share them in the comments below.

Happy coding 🙂

Shane Bartholomeusz