Does anyone know if it's possible to copy text from a Windows' command prompt or console window like the output of a command, console application or batch file?
10 Answers
Another option, if you know ahead of time that you want the results of a command to be placed on the clipboard, is to pipe your output to the CLIP utility.
Here are a two simple examples
echo Hello world!|clip
dir|clip

- 127,446
- 28
- 251
- 390
-
Is clip available in window xp @dbenham ? – Pie Nov 29 '19 at 09:46
-
@Pie - No, it was introduced with Vista. Before that it was only available in the Windows 98 Resource Kit. – dbenham Nov 29 '19 at 13:06
- Right click > Mark
- Select the text you want to copy by holding left mouse button and selecting text OR by navigating to the beginning of the text you want to copy with the arrow keys, pressing Shift, and moving (with the arrow keys) to the end of the text.
- right click on the title bar, go into "Edit", and hit Copy.
Now you can paste in Notepad or in Command Prompt again by right-clicking on the title bar, going into "Edit", and hitting "Paste."

- 467
- 7
- 14
-
11You can also press Enter after selecting your text eliminating the need to hit Edit->Copy. – graham.reeds Jul 18 '12 at 15:35
-
1You can also enable QuickEdit Mode in the preferences (click the icon in the top left, select preferences), that allows you to skip the right-click menu entirely. Select with LMB and drag, copy with enter, paste with RMB – Tzalumen Dec 21 '17 at 16:34
Open a command window, then right click on the title bar and left click on Properties at bottom of context menu. On the Options tab add a check-mark at QuickEdit Mode. Click OK and in the next dialog select the second radio button so that every command window that you will open in future has got this option enabled. Close the dialog with OK.
Now you can select text using left click on your mouse. To copy the text to the clipboard, just press the Enter key.
Follow these steps:
- Move pointer with pointing device (mouse, touchpad, pointing stick, ...) over the window, press right button to open the context menu and left click on first context menu option Mark.
- After that action select the text with holding left button (rectangular selection).
- After selecting hit key Enter or Return to copy selected text to clipboard.
- Paste copied text anywhere with Ctrl+V.
- Right Click > Mark
- Select the text you want to copy with left click held
- Right click on the selected text
- Paste where you want

- 321,522
- 82
- 660
- 783
Sure you can! right-click, choose mark, select the needed text and right click again to copy the text.
You could also choose QuickEdit mode from the cmd menu, that way you don't have to right click and select mark, but can select copy directly.

- 17,318
- 6
- 67
- 91
Haloo my friend :
if you want to copy any text which was currently in the clipboard in
the Cmd or in the PowerShell you should Just :
1\ Write any command that you want .
2\before pressing enter write |clip and then press Enter .
3\Open any text Editor such as Notepad .
4\ Ctrl+v or Right click -Paste .
and her you have the clipboard in your Text Editor ^_^ .

- 21
- 1
On PowerShell:
Copy contents in a text file to the clipboard. Use
cat filename.txt | clip
the contents will be copied to the clipboard.
Now, it's ready to ctrl + v

- 61
- 4
If you right click and mark in the context menu you can then drag to edit the selection and then press Ctrl+c and it should copy to the clipboard

- 1,204
- 11
- 20
-
1I tried. But as soon as I right-clicked. The selection disappeared. – user1508893 Jul 18 '12 at 18:01
Select the text you want to copy. Then right click and select copy from menu. To paste in cmd right click, the text you copied should be pasted

- 11
- 2