Prevent Visual Studio to scroll to the end of file when pressing Ctrl A (select all)

No, you cannot change this behavior.

Microsoft has been aware of this since at least VS 2010, but either doesn't think it's a bug or doesn't think it's important enough to fix.

From their response to a 2010 bug report filed on the issue:

We unfortunately do not plan to change Ctrl+A's scrolling at this time, so we're unfortunately resolving this issue as Won't Fix for VS 2010. However, it will remain in our database to be revisited for a future release of Visual Studio.

Source: Microsoft Connect


A quick Ctrl-Z-Ctrl-Y will get you back to where you were. If you tend to do a Ctrl-S Ctrl-A Ctrl-C a lot then just get used to this whole chain instead: Ctrl-SACZY. Or, create a macro: https://msdn.microsoft.com/en-us/library/a0003t62%28v=vs.90%29.aspx


I was struggling with this myself, but the "undo" suggestion gave me an idea and I feel kinda dumb for not thinking of it earlier. Visual Studio includes "Navigate Backwards" and "Navigate Forwards" buttons (CTRL-, and CTRL+, respectively). So after you finish selecting and copying, simple click the navigate backwards button or type CTRL- and voilà! you're back where you were.

I know it doesn't stop the scroll to begin with, but at least it puts your cursor back exactly where you left it!