What is ctrl-c in Visual Studio 2012?

Source: Internet
Author: User

Ctrl-c copy a piece of code (Ctrl-x is the same problem)

The cursor moves to the blank line position where you want to paste the code (typically pasted on a blank line)

Hold down the CTRL key, and when you are ready to press the V button, a distraction or a shake of the hand, the finger falls on the C key.

You come back to see, nothing is pasted out, just move the cursor down one line.

You think you did not press the key, and then several consecutive ctrl-v, see the cursor down one line, still nothing.

At this point, if you know Shift-ctrl-v (cycle Clipboard Ring) This shortcut, may not be how angry, press two shift-ctrl-v will be able to solve the problem, but if you do not know the shortcut, you will be very annoyed, can only be reproduced, if it is cut, Your irritation will double.

After copying a large chunk of the "clipboard with CTRL + C, I move the" cursor to "correct spot in another file a D paste it with Ctrl + V. Oh wait, except instead of CTRL + V my fingers hit Ctrl + C. Even though I didn ' t highlight any new text, the editor threw me entire careful in the Clipboard and garbage it W ith the current line, forcing me to go back to the other file which I might have from now. This is a EXTREME pain in the backside, something I can ' t turn off (the existing setting only claims to work on Blank Lin Es, and doesn ' t even get-right), and something that Visual C + + never used to do before visual Studio. NET or whatever You call this. Would I have to write a extension that stops the editor from mindlessly performing the copy hotkey in any text that isn ' t Even selected?

Microsoft has not ignored this feedback and provided solutions in VS2012 (found on StackOverflow):

It ' s not copying a empty block, it's copying the blank line. Can change this setting into Tools > Options > Text Editor > All Languages > ' Apply/Copy Commands to Blank lines when there is no selection '.

The workaround is simple, just cancel the option of ' Apply cut or Copy Commands to blank lines when there is no selection '.

Although it is not possible to understand why there is a need to replicate empty lines, if so, it is acceptable.

However, why the default setting is to copy empty lines, which is contrary to everyone's daily operating habits. In the editor I used, I didn't encounter an editor that would copy empty rows in addition to Visual Studio, even if it was a notepad from Windows. This really can't understand!

Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

11.11 Big Sale for Cloud

Get Unbeatable Offers with up to 90% Off,Oct.24-Nov.13 (UTC+8)

Get It Now >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.