Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Copy Content to Clipboard - Add to Context Menu


Copy Content to Clipboard - Add to Context Menu

How to Add "Copy Content to Clipboard" to Context Menu in Vista, Windows 7, and Windows 8
Published by Brink
06 Feb 2011
Published by

How to Add "Copy Content to Clipboard" to Context Menu in Vista, Windows 7, and Windows 8

information   Information
This tutorial will show you how to add or remove Copy to Clipboard from the right context menu of BAT, CMD, CSS, HTML, JS, LOG (txt), REG, RTF, TXT, and VBS files in Vista, Windows 7, and Windows 8.

If added, this makes it a lot easier to copy the entire contents of a file with one of these file extensions to the clipboard, then paste the contents where you like.

Note   Note
This will not work for the RTF (WordPad) file extension context menus if you have Microsoft Office Word installed and set as the default program to open RTF files instead of WordPad.


EXAMPLE: Context Menu with "Copy Content to Clipboard" Added or Removed
Name:  Default.jpg
Views: 1631
Size:  33.0 KBName:  Added.jpg
Views: 1637
Size:  37.3 KB



OPTION ONE
Add or Remove "Copy Content to Clipboard" using REG File

NOTE: This option will allow you to automatically add or remove Copy to Clipboard from all of the context menus of the BAT, CMD, CSS, HTML, JS, LOG (txt), REG, RTF, TXT, and VBS files at once.
1. Do step 2 or 3 below for what you would like to do.

2. To Add "Copy Content to Clipboard"
A) Click/tap on the download button below to download the file below, and go to step 4 below.
Add_Copy_Content_to_Clipboard.reg
download
3. To Remove "Copy Content to Clipboard"
A) Click/tap on the download button below to download the file below, and go to step 4 below.
Remove_Copy_Content_to_Clipboard.reg
download
4. Save the .reg file to your Desktop.

5. Double click/tap on the downloaded .reg file to merge it.

6. Click/tap on Run, Continue (UAC-Vista) or Yes (UAC-Windows 7/8), Yes, and then OK when prompted.

7. When done, you can delete the downloaded .reg file if you like.



OPTION TWO
Add or Remove "Copy Content to Clipboard" in Registry Editor

NOTE: This option will allow you to manually pick and choose to add or remove Copy to Clipboard from either one, more, or all of the context menus of the BAT, CMD, CSS, HTML, JS, LOG (txt), REG, RTF, TXT, and VBS files.
1. Press the Windows + R keys to open the Run dialog, type regedit, and press Enter.

2. If prompted by UAC, then click/tap on Continue (Vista) or Yes (Windows 7/8).

3. Do step 4 or 5 below for what you would like to do.

4. To Add "Copy Content to Clipboard" to the Context Menu
A) In regedit, navigate to the location below for the file extension that you wish to add Copy Content to Clipboard to.
  • HKEY_CLASSES_ROOT\batfile\shell
  • HKEY_CLASSES_ROOT\cmdfile\shell
  • HKEY_CLASSES_ROOT\CSSfile\shell
  • HKEY_CLASSES_ROOT\htmlfile\shell
  • HKEY_CLASSES_ROOT\JSFile\shell
  • HKEY_CLASSES_ROOT\regfile\shell
  • HKEY_CLASSES_ROOT\rtffile\shell
  • HKEY_CLASSES_ROOT\txtfile\shell
  • HKEY_CLASSES_ROOT\VBSFile\shell
B) In the left pane of regedit, right click on shell, click/tap on New and Key, type Copy Content to Clipboard, and press Enter. (see screenshot below)
Name:  REG1.jpg
Views: 1726
Size:  62.5 KB
C) In the right pane of Copy Content to Clipboard, right click on a empty space, click on New and String Value, type Icon, press Enter, and double click/tap on Icon to modify it. (see screenshot above)

D) In the Edit String box, copy and paste the commmand below, and click/tap on OK.
DxpTaskSync.dll,-52
E) In the left pane of regedit, right click on Copy Content to Clipboard, click/tap on New and Key, type command, and press Enter. (see screenshot below)
Name:  REG2.jpg
Views: 1651
Size:  60.5 KB
F) In the right pane of command, double click/tap on (Default) to modify it. (see screenshot above)

G) In the Edit String box, copy and paste the commmand below, and click/tap on OK.
cmd /c clip < "%1"
H) Repeat step 3 above for any other file extenstion that you wish to add Copy Content to Clipboard to it's context menu.

I) When finished, go to step 6 below.
5. To REMOVE "Copy Content to Clipboard" from the Context Menu

A) In regedit, navigate to the location below for the file extension that you wish to remove Copy Content to Clipboard from.
  • HKEY_CLASSES_ROOT\batfile\shell\Copy Content to Clipboard
  • HKEY_CLASSES_ROOT\cmdfile\shell\Copy Content to Clipboard
  • HKEY_CLASSES_ROOT\CSSfile\shell\Copy Content to Clipboard
  • HKEY_CLASSES_ROOT\htmlfile\shell\Copy Content to Clipboard
  • HKEY_CLASSES_ROOT\JSFile\shell\Copy Content to Clipboard
  • HKEY_CLASSES_ROOT\regfile\shell\Copy Content to Clipboard
  • HKEY_CLASSES_ROOT\rtffile\shell\Copy Content to Clipboard
  • HKEY_CLASSES_ROOT\txtfile\shell\Copy Content to Clipboard
  • HKEY_CLASSES_ROOT\VBSFile\shell\Copy Content to Clipboard
B) In the left pane of regedit, right click on Copy Content to Clipboard, and click/tap on Delete. (see screenshot below)
Name:  Delete-1.jpg
Views: 1544
Size:  59.7 KB
C) Click/tap on Yes to approve deleting the key. (see screenshot below)
Name:  Delete.jpg
Views: 1533
Size:  24.5 KB
D) Repeat step 4 above for any other file extenstion that you wish to remove Copy Content to Clipboard from it's context menu.

E) When finished, continue on to step 6.
6. Close Registry Editor.
That's it,
Shawn



06 Feb 2011   #1
EzioAuditore

Winbdows 7 ultimate x64 | Ubuntu 12.04 x64 LTS
 
 

It's very useful, thanks Shawn.
It'd be nice if you can add the manual way too..

Shawn, can you explain a thing, just for my knowledge?

Code:
;For BAT files
[HKEY_CLASSES_ROOT\batfile\shell\Copy to Clipboard]
"Icon"="DxpTaskSync.dll,-52"
 
[HKEY_CLASSES_ROOT\batfile\shell\Copy to Clipboard\command]
@="cmd /c clip < \"%1\""
 
 
;For CMD files
[HKEY_CLASSES_ROOT\cmdfile\shell\Copy to Clipboard]
"Icon"="DxpTaskSync.dll,-52"
Here, the registry entries part are same in all cases, so, how're the diff. extentions get sorted?

I mean do these parts ";For BAT files", ";For CMD files" differentiate b/w them?


My System SpecsSystem Spec
06 Feb 2011   #2
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

Hello Ezio,

I'm going to work on a manual part late tonight to be added to help better with this though.

The ;text...... parts are just comments to help tell what each section is for, and serve no other purpose. If you look at each [HKEY_CLASSES_ROOT\batfile...... part after that in each section, you will notice that this is where the difference is.
My System SpecsSystem Spec
06 Feb 2011   #3
EzioAuditore

Winbdows 7 ultimate x64 | Ubuntu 12.04 x64 LTS
 
 

Thanks Shawn. It's clear now.
My System SpecsSystem Spec
07 Feb 2011   #4
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

You're welcome.

I've added the manual Option Two to the tutorial to help people to easily pick and choose what file extension they would like to have Copy to Clipboard added to or removed from.
My System SpecsSystem Spec
07 Feb 2011   #5
Bill2

Windows 7 x64 pro/ Windows 7 x86 Pro/ XP SP3 x86
 
 

Good stuff Shawn. Cant rep you..need to spread the love.
My System SpecsSystem Spec
07 Feb 2011   #6
EzioAuditore

Winbdows 7 ultimate x64 | Ubuntu 12.04 x64 LTS
 
 

Very well, thanks again Shawn.
My System SpecsSystem Spec
07 Feb 2011   #7
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

You're most welcome guys. Thank you.
My System SpecsSystem Spec
17 Jul 2011   #8
l3ny

7x64
 
 

How about html, js and css files. thanks.
My System SpecsSystem Spec
17 Jul 2011   #9
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

Hello l3ny, and welcome to Seven Forums.

Those file extensions have been added to the tutorial.
My System SpecsSystem Spec
Comment

 Copy Content to Clipboard - Add to Context Menu




Tutorial Tools



Similar help and support threads for2: Copy Content to Clipboard - Add to Context Menu
Windows 7 Tutorial Category
Solved How to add a "Copy Shortcut text" context menu item Customization
Saving Clipboard Content in Word 2010 Microsoft Office
Remove Userfolder and desktop from Copy to Move to context menu Customization
How to remove Cut, Copy & Paste options from context menu? Customization
Does Clipboard content get stored in... General Discussion

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 08:38 AM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App