Newbie Question: How do I turn off the #1, #2, etc at the start of each line?

Topics: User Forum
Feb 8, 2008 at 5:05 AM
I am a complete newbie to PowerShell and the Community Extensions and I just installed the Community Extensions. After installing it I get prompted on each line inside PowerShell with a "#<linenumber>" i.e. #1 then #2, etc.

How do I turn this off and go back to the way it was? Also, is there some benefit to having this line numbering that I should consider to use it instead of reverting back to what I had.

Thanks!
...Ed
Coordinator
Feb 8, 2008 at 6:04 PM
You can open up your profile script by executing the alias "ep" and then comment out (or remove) this line towards the bottom of the file:

. $PscxEyeCandyScriptPreference

You will notice the change in new PowerShell sessions. BTW the benefit of the number is that corresponds to PowerShell's command history. Look up help on Get-History and Invoke-History. So if I see a command up at the top of my console like say:

32# Gci . *.vcproj -r | select-string regsvr32

I can execute it again by entering "r 32".
Feb 13, 2008 at 2:17 AM
Thanks Keith! In light of what you say, I think I'm going to keep this feature on for the time being.