June 15th, 2014

PowerTip: Send Output to Clipboard with PowerShell

Doctor Scripto
Scripter

Summary: Use Windows PowerShell to easily send output to the clipboard.

Hey, Scripting Guy! Question How can I easily capture output from the Windows PowerShell console and send it to the Windows Clipboard
          so I can paste it into another program?

Hey, Scripting Guy! Answer The standard Windows utility clip.exe accepts pipeline output, for example:

Get-EventLog application -Newest 1 | clip

Author

The "Scripting Guys" is a historical title passed from scripter to scripter. The current revision has morphed into our good friend Doctor Scripto who has been with us since the very beginning.

0 comments

Discussion are closed.