Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > PowerShell

Vista - Right-click on PS RC2 window automatically runs whatever is on clipboard

Reply
 
Old 10-20-2006   #1 (permalink)
PowershellBoy


 
 

Right-click on PS RC2 window automatically runs whatever is on clipboard

When I copy code, and then only right-click on a Powershell RC2 window
with the intent of pasting (even thought to paste correctly I should
click on the titlebar of the window and choose Edit | Paste), the code
that had been copied to the clipboard is automatically pasted, and
runs.

I kind of like this. But does that sound like expected behaviour?


My System SpecsSystem Spec
Old 10-20-2006   #2 (permalink)
Oisin Grehan


 
 

Re: Right-click on PS RC2 window automatically runs whatever is on clipboard

Yeah, this is expected behaviour, however: this is a function of the
console window host, not powershell. It can't distinguish between
pasted input and manually typed input. The only reason it is
automatically executed is because you've copied a trailing CRLF also.
If you carefully copy only the text, it will not run until you hit
<enter> manually.

- Oisin

PowershellBoy wrote:
> When I copy code, and then only right-click on a Powershell RC2 window
> with the intent of pasting (even thought to paste correctly I should
> click on the titlebar of the window and choose Edit | Paste), the code
> that had been copied to the clipboard is automatically pasted, and
> runs.
>
> I kind of like this. But does that sound like expected behaviour?


My System SpecsSystem Spec
Old 10-20-2006   #3 (permalink)
Adam Milazzo


 
 

Re: Right-click on PS RC2 window automatically runs whatever is onclipboard

PowershellBoy wrote:
> When I copy code, and then only right-click on a Powershell RC2 window
> with the intent of pasting (even thought to paste correctly I should
> click on the titlebar of the window and choose Edit | Paste), the code
> that had been copied to the clipboard is automatically pasted, and
> runs.
>
> I kind of like this. But does that sound like expected behaviour?


Yes. And this behavior can be toggled by right-clicking the powershell
task item or opening its system menu in the top-left corner, choosing
Properties, and enabling or disabling the Quick Edit feature. You can
set many other things there as well.
My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
drvinst.exe runs automatically & eats 40% of CPU in Vista Home Pre Vista General
Adding a program to startup list so it runs automatically Vista General
drvinst.exe runs automatically & eats 40% of CPU in Vista Home Pre Vista installation & setup
drvinst.exe runs automatically & eats 40% of CPU in Vista Home Pre Vista hardware & devices
drvinst.exe runs automatically & eats 40% of CPU in Vista Home Pre Vista performance & maintenance


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46