Questions tagged [copy-paste]

For issues relating to cut, copy, and paste operations.

The term "copy-and-paste" refers to the popular, simple method of reproducing text or other data from a source to a destination. It differs from cut and paste in that the original source text or data does not get deleted or removed. The popularity of this method stems from its simplicity and the ease with which users can move data between various applications visually – without resorting to permanent storage.

Source: Wikipedia

3477 questions
18
votes
8 answers

SSMS Copy and Paste Without Header

How do I copy and paste one record from SSMS 2012 without the header (when it comes along without me asking for it)? In SSMS, Tools -> Options -> Query Results -> SQL Server -> Results to Grid -> "Include column headers when copying or saving the…
user2313215
  • 191
  • 1
  • 5
18
votes
6 answers

Why after copying git repository to another dir I have modified files?

I have my personal small git repository on my laptop. I have just commited the changes and checked that I have nothing to commit - every staged and modified file has been commited. After that I have copied all the files from this repo to another…
Patryk
  • 22,602
  • 44
  • 128
  • 244
18
votes
1 answer

copy-paste lines between tabs in vimdiff

I'm using vimdiff to see the difference between two files. I'm wondering if it is possible to copy a line from the left tab (the first file) and paste it in the second tab (the second file). Actually, I can't even seem to be able to access the…
nay
  • 864
  • 2
  • 8
  • 12
17
votes
3 answers

What exactly is the effect of Ctrl-C on C++ Win32 console applications?

Is it possible to handle this event in some way? What happens in terms of stack unwinding and deallocation of static/global objects?
Assaf Lavie
  • 73,079
  • 34
  • 148
  • 203
17
votes
4 answers

How can I paste NeoVim registers in terminal mode?

When using NeoVim's :terminal feature, I'd like to be able to paste text from a register. When working with a standard text buffer, I frequently use two methods to paste text from a register: in Normal mode: "{register}p in Insert mode:…
nelstrom
  • 18,802
  • 13
  • 54
  • 70
17
votes
3 answers

Eclipse is hanged on copy/paste in JavaScript files

I've been running Eclipse Helios 3.6 using the Java/CFEclipse IDEs, and finding some very strange and aggravating errors when trying to edit Javascript files. After the .js file reaches a certain size (~250 lines of code), Eclipse will randomly hang…
user417589
  • 171
  • 1
  • 1
  • 5
17
votes
6 answers

Similar code detector

I'm search for a tool that could compare source codes for similarity. We have a very trivial system right now that has huge amount of false positives and the real positives can easily get buried in them. My requirements are: reasonably small amount…
Šimon Tóth
  • 35,456
  • 20
  • 106
  • 151
17
votes
1 answer

Is is possible to put into clipboard the result of a shell command?

Imagine I do: echo $PATH in a terminal. Is is possible that the result is automatically copied so that if I do Ctrl+y it would get printed? As I understand it, when doing Ctrl+k on a terminal, the text is saved in a memory buffer that belongs to…
elelias
  • 4,552
  • 5
  • 30
  • 45
16
votes
4 answers

When I paste text to a NSTextView, how to paste plain text only?

When I paste text to a NSTextView, I wish I can paste plain text only. All the rich text formats should be removed, include: font, color, link, and paragraph style. All the text pasted should be displayed with the default font and style of the text…
Stephen Hsu
  • 5,127
  • 7
  • 31
  • 39
16
votes
3 answers

How to copy UIImage data to clipboard/UIPasteboard? And how do I test it?

I tried to use the following code to copy the Image data to UIPasteboard on click of the Copy item in the menu. UIPasteboard *gpBoard = [UIPasteboard generalPasteboard]; [[gpBoard setData:UIImageJPEGRepresentation(imgView.image, 1.0)…
pradeepa
  • 4,104
  • 5
  • 31
  • 41
16
votes
4 answers

R - Autofit Excel column width

How do I autofit the column width using openxlsx? One of my columns has a date variable (eg. 21-08-2017) and if copied using ctrl+c from Excel, and pasted normally elsewhere, it shows like #######(if column width is increased to show the content in…
Arani
  • 753
  • 1
  • 9
  • 23
16
votes
2 answers

Android - edittext - no textselection handles are shown and no sharing option

On an App screen I have a number of EditText views. My app is built using the Material Design (AppCompactActivity, etc). While showing an EditText field, with a long press I try to select a number of words in the text. This allows me to copy or…
tm1701
  • 7,307
  • 17
  • 79
  • 168
16
votes
1 answer

Copy to clipboard as plain text

I'm using this code in background.js in a Chrome extension to copy text to the user's clipboard: chrome.runtime.onMessage.addListener( function(request, sender, sendResponse) { if (request.command == "copy") { …
16
votes
10 answers

CopyPicture method of range class failed - sometimes

I have a VBA code which I am using to copy ranges as a picture and paste them into a chart. It does this so I can save it into a picture. This code has like a 70% success rate, and when it doesn't work, it gives out the error "CopyPicture method of…
Horace
  • 252
  • 2
  • 4
  • 15
16
votes
2 answers

Error when selecting text from Textview (java.lang.IndexOutOfBoundsException: setSpan (-1 ... -1) starts before 0)

I am trying add copy paste functionality on text view.I have added in code registerForContextMenu(detailedText); and also android:textIsSelectable="true" in xml.When I am trying to copy it works well,but when it pointed on first position of the…
Mayur Raval
  • 3,250
  • 6
  • 34
  • 57