Welcome to MSDN Blogs Sign in | Join | Help

clip it

In PowerShell I ran (dir *.exe).Count to see the number of executables in System32 folder in a Vista box and it prompty returned 401. So there are 401 executables and most of us are unaware of most of them.

Recently I wanted to copy the output of a console application to the clip board. I was on the verge of writing a program to do just that when I reminded myself of the programmers disease. After a bit of digging around I found the neat little clip.exe in the system32 folder.

d:\prithvi\Setup>clip /?

CLIP

Description:
    Redirects output of command line tools to the Windows clipboard.
    This text output can then be pasted into other programs.

Parameter List:
    /?                  Displays this help message.

Examples:
    DIR | CLIP          Places a copy of the current directory
                        listing into the Windows clipboard.

    CLIP < README.TXT   Places a copy of the text from readme.txt
                        on to the Windows clipboard.

So clip does what I was exactly looking for. Its a neat tool and I have grown fond of it. Guess how I pasted the output above. I ran clip /? | clip :-)

Published Friday, July 14, 2006 6:00 PM by abhinaba

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

# re: clip it

Friday, July 14, 2006 9:25 AM by David Mohundro
I wish I had known about that a long time ago! It looks like it is/was part of the Resource Kit Tools for Windows Server 2000 or NT somewhere, so it doesn't look like it comes with a Windows XP Professional installation (as far as I could tell). After some searching online, I stumbled across a link to this Microsoft FTP site: ftp://ftp.microsoft.com/Services/TechNet/samples/ps/win98/reskit/file/. clip.exe can be downloaded from there.

# Interesting Find for Command Prompt junkies

Friday, July 14, 2006 12:34 PM by Peter Ritchie's MVP Blog
Pipe data from a file or command to the clipboard in the Command Prompt!

# Interesting Finds: July 14, 2006

Friday, July 14, 2006 11:13 PM by Jason Haley

# re: clip it

Saturday, December 09, 2006 2:35 PM by Erik van der Gaag

# re: clip it

Thursday, April 19, 2007 10:57 AM by Michael Zand

Hi,

I'm looking for the complement of clip.  In other words, a command which pastes the contents of the clipboard to the command prompt.  I know I can do this using the right mouse button but I would like a way to do it without using the mouse.

-Michael

mzand@hotmail.com

# re: clip it

Friday, May 18, 2007 2:17 PM by Jon Schneider

@Michael Zand:

To paste the clipboard contents to a cmd.exe window using only the keyboard, try:  Alt+Space, e, p.  (Alt+Space opens the window's Titlebar menu, e for Edit, p for Paste.)  Not terribly elegant, but it works!

Leave a Comment

(required) 
required 
(required) 

  
Enter Code Here: Required
 
Page view tracker