Visual Studio: how can I see the same file in two separate tab groups?

I want to be able to edit one method, looking at another method in the same file as the link. It can be done?

+131
visual studio
Jan 14 '09 at 19:42
source share
7 answers

You can open the file in another tab ( Window New Window ).

You have two copies of the same file. Then you can right-click on the tab bar and select New Vertical Tab Group (or New Horizontal Tab Group , the one you like best).

I hope I understand that you are in doubt.

+198
Jan 14 '09 at 19:53
source share
— -

Only vertically that I know. When viewing the code, right above the vertical scroll bar there is a small rectangle, drag it down to get a split view of the file.

+71
Jan 14 '09 at 19:45
source share

Being on the tab you want to duplicate
then click on the menu bar at the top
Window > New Window

et voila, here you have it :)

EDIT

It seems that this feature is not implemented in all versions of VS.
In my case ( Visual Studio Community 2017 V 15.4.2 ) it works fine.

(German text - "Fenster" = "window")

/img/865d7e9a84e53b4a575f1cccdf54885b.png

V 15.4.2

+36
Sep 27 '17 at 11:33 on
source share

You simply use the small drag and drop arrow icon in the upper right corner of your file window, as shown in the following screenshots:

Before dragging

After dragging

+28
Feb 09 '17 at 8:57
source share

1) View the same document side by side (with fix for Visual Studio 2017)

This can be done using the New Window and New Vertical Tab Group , however, in my Visual Studio 2017, the New Window command was missing from the Window menu. To use it, you must first add a command to the menu or assign a shortcut to it.

To add a New Window to your Window menu, follow this sequence, starting with the Tools menu:

Tools > Customize > Commands > Menu Bar > Window > Add Command > Window > New Window

FYI In the Commands step, you decide where to put the New Window command. The sequence I gave above makes it unceremoniously at the top of the Window menu.

To view the same document side by side

  • Open the document you want to view side by side
  • Select the recently added New Window command (perhaps it is in Window > New Window )
  • Right-click on the new tab and select New Vertical Tab Group or select this command from the Window menu.

2) View the same document above one another

If you want to view the same document in two views, one above the other, use the Window > Split command or click and drag the double arrow at the top of the scroll bar for any window.

3) Create an ad

Fyi. You can even combine two view options with three, four or even more views of the same document on a particularly wide monitor. On my (2560 x 1080) I can comfortably get three side views, walking and , if desired, break them down vertically. multiple panels

+14
Aug 22 '17 at 7:50
source share

You can install the VsVim extension and :sp :vsp does the trick.

+4
Aug 23 '16 at 9:21
source share

In Visual Studio 15, you can simply click inside the document and then "Window -> Split"

+3
Feb 20 '17 at 8:26
source share



All Articles