Closing files with the Visual Studio Popup Navigator Window? - visual-studio

I'm looking for a quicker way to close files in visual studio so I can avoid X'ing out of a file, or hitting ctrl+f4. These are too slow for closing multiple files.
Is it possible to configure the popup navigator window (ctrl+tab) to close files somehow?
Like maybe clicking a file with the middle click on a mouse, or area dragging over a few files and hitting del?
I'd also welcome any other way of closing multiple files in a quick manner.

Works for me by clicking the middle mouse button down anywhere on the tab towards the top of the window.
Perhaps you could remap the keyboard shortcut from 'ctrl + f4' to 'ctrl + w' to mimic typical behavior of other applications? Keyboard shortcuts can be accessed through:
Tools>Options - then look for Keyboard under the Environment tab. To access the shortcut for closing a tab, search for Window.CloseDocumentWindow
Hope that helps - I'm unaware of any means to close multiple windows at once.

Related

How do I stop Visual Studio 2022 find starting a new set of editor tabs?

I use various finds to do basically all my navigation in VS... haven't been back to .NET for a while, and are using VS 2022, but there's a behaviour I can't handle, and I'm wondering how to stop it.
Basically
I have a set of code open in a bunch of tabs.
I hit the key to open the "find in files" window and put in a search
It opens a new pane with find results in it.
Clicking on any file inside the find results opens that file IN THIS NEW PANE
So suddenly I have two sets of editor tabs. I never want two sets of editor tabs.
How do I stop it doing this?
It sounds like your Find Results window is Docked as Tabbed Document. In this case, right click the Find Results tab and select Dock to fix the problem.

Open file in Visual Studio's split window which is already open in another window

using Visual Studio 2019 Community here.
I have two windows split vertically (that is to say, a window on the left and one on the right) and I have a bunch of .h files open in my left window.
If I'm currently in the right-hand window, and use ctrl+shift+t (or ctrl+tab) to select a file which is already in a tab on the left window, it will open that tab in the left window and re-focus my cursor to the left window.
This sucks.
Is there a shortcut to either:
a) Open that file again but in the right window which I'm currently focused on, or
b) Move a currently-focused tab on the left window over to the right window?
I largely try to avoid using my mouse when I'm programming, so I'm also using VsVim if that helps or makes a difference.
Thanks!
Looks like there are options for you to assign your own keyboard bindings.
Tools > Options > Environment - Keyboard
Assign shortcuts to Window.MoveToNextTabGroup and Window.MoveToPreviousTabGroup.

Navigate to open files / open tabs

Problem: Some times I have many tabs open and finding a tab is not easy and fast.
Question: Is there any shortcut in visual studio or resharper that allow us to find a tab by typing part of file/tab name?
Example: Something like Navigate-> Recent files... of resharper:
Looking up the ReSharper 2017.2 Help - Navigation and Search I could not find any hint about navigating through active files.
Visual Studio allows you to navigate through all open tabs by using Ctrl + Tab. This allows you to switch trough all open tabs ordered by their latest use. Use Ctrl + Tab again for forward and Ctrl + Shift + Tab for backward navigation. But as you already mentioned with a lots of open tabs it could be slow stepping through all active files.
What I personally do in your situation, when trying to find a open tab or any kind of class/file/member, is to use the Ctrl + T shortcut. This opens the Go to Everything/Type … popup, which allows you to search for anything within you solution.
To find an item in your solution by the item's name
To use the unified access to all search results, press Ctrl+T to display a pop-up where you can start typing and find everything in your solution that matches your input.
If you want to limit your search to types (classes, interfaces, structs or enums), press Ctrl+T twice.
If you want to find anything by a plain textual match, press Ctrl+T three times.
If you want to search symbols (types, methods, properties, fields, and so on) - press Shift+Alt+T.
You can also limit the search to files in your solution by pressing Ctrl+Shift+T.
from ReSharper Help - Navigation by Name
More Shortcuts: Resharper - Default Keyboard Shortcut Schemes
Yoy can try set shortcut to open window with active tabs: Options -> KeyBoard -> Window.Windows
It will look something like this

How can I close the solution explorer panel with a key-board shortcut in Visual Studio 2010?

I often need to jump from a file to another file that I don't have open to one somewhere in the project directory structure. I often use Ctrl-Alt-L to open the solution explorer panel, but then I'd like to close it after I open the file I'm after. Unfortunately Ctrl-Alt-L doesn't simply toggle the panel open/closed. Is there another way to accomplish this. Or how can I close the solution explorer panel with a key-board shortcut?
I believe you are looking for SHIFT+ESCAPE.
It will close any tool window currently in focus.
Turn on the Auto-Hide option for the Solution Explorer panel. Now you can open it with Ctrl+Alt+L and close it with Esc. Actually Esc will set the focus back to the code editor and the Solution Explorer will auto-hide itself.
It takes two steps:
CTRL + ALT + L to put the Solution Explorer into focus.
Then SHIFT + ESC to close the tool window currently in focus.
Thank you Smash for the second step.
Turn on Auto-Hide in the Solution Explorer panel, then press Ctrl + Tab and release only the Tab key, that will open this dialog with Active Tools and Active Files lists. Select your prefered item using the keyboard or mouse.

'Property pages' tab is missing in VS2010

On the right of VS2010, there is normally a group of tabs, like the solution explorer and the property pages tab. It seems that the tab to access the property pages is missing.. How can I get it back? This must be easy.
The tabs will only appear if more than one window is docked at the same spot. If you don't see them then you either have undocked the window or closed them. Closing be the more likely case here, use the View menu to get them back. Or Windows + Reset Window Layout if you're completely lost.
Click on the Project name in the Solution Explorer and then press F4. The Properties window/tab should now appear.
Note that this Properties tab is different than the one shown if you right click the project name and then click "Properties."
Under View Dropdown menu, should be there.
Or right click on the app in design mode and click properties.
Close your visual studio and open the Visual Studio Command Prompt (from window Start -> Programs -> Visual Studio XXXX -> Visual Studio XXXX Tools) and enter "devenv /setup".
If you want to dock one below the other it's a two step operation. You need to start with the two windows not connected together at all.
1) dock the first window on the right hand side of the application. This should fill all of the vertical space available.
2) make sure the second window is floating then drag it towards the first. When the arrows appear move the mouse over the down arrow and the second window should snap below the first.

Resources