Add to Technorati Favorites Add to Google

Copy Text file contents to the Clipboard using the Context menu

To copy the contents of a text-based file, you open the file in an editor such as Notepad, use Select All and then copy the contents. How about accomplishing it using a command in the context menu?

Add "Copy to Clipboard" option in the Context menu

Note: The following tweak works fine in Windows XP and Windows Vista. If you are using Windows XP, you should download clip.exe from Microsoft site in order for the Copy to Clipboard option to work.

1. Launch Regedit.exe and navigate to the following branch:

HKEY_CLASSES_ROOT \ SystemFileAssociations \ text \ shell

2. Create a subkey named Clipboard.

3. Double-click (default) and set Copy to Clipboard as its Value data

4. Under Clipboard, create another subkey named command

5. Select the following key:

HKEY_CLASSES_ROOT \ SystemFileAssociations \ text \ shell \ Clipboard \ command

6. Double-click (default) and set its Value data to:

cmd.exe /c type "%1" |clip.exe

7. Exit the Registry Editor.

Now, right-click on a text file and choose Copy to Clipboard. This copies the text file contents to the Clipboard. To verify, you may open Notepad.exe and press CTRL+V to paste the contents from Clipboard.

Registry Fix

To automate the above, download clipcontents.zip and extract the files to a folder. Double-click clipcontents.reg to run it.

RELATED POSTS


BOOKMARK THIS PAGE

BlinkList | del.icio.us | Digg it | Furl | ma.gnolia | Newsvine | reddit | Spurl | Wink |


If you enjoyed this post, make sure you subscribe to our RSS feed! We feature Tips, Troubleshooting information, Scripts and Utilities for Microsoft Windows Operating Systems!
Prefer an E-mail subscription?

Enter your email address:

Delivered by FeedBurner

There Are 3 Responses So Far. »

  1. Great find, thanks!

  2. Nice edit, thanks! :)

  3. Does anyone know how to make ‘Copy to Clipboard’ appear under ‘Cut’ and ‘Copy’ please?

    Thanks. :)

Post a Response