Showing archive results for December 2014

Dec 6, 2014
Post comments count0
Post likes count0

PowerTip: Use PowerShell to Replace Characters in String

Doctor Scripto

Summary: Use Windows PowerShell to replace non-alphabetic and non-number characters in a string.  How can I use Windows PowerShell to replace every non-alphabetic and non-number character in a string            with a hyphen?  Use the Windows PowerShell –Replace operator and the \w&n...

Scripting Guy!Windows PowerShellPowerTip
Dec 6, 2014
Post comments count1
Post likes count0

Weekend Scripter: Remove Non-Alphabetic Characters from String

Doctor Scripto

Summary: Microsoft Scripting Guy, Ed Wilson, talks about using Windows PowerShell to remove all non-alphabetic characters from a string. Microsoft Scripting Guy, Ed Wilson, is here. This morning I am drinking a nice up of English Breakfast tea and munching on a Biscotti. I know...Biscotti is not a very good breakfast. Oh well. I went to my favorite...

Scripting Guy!Windows PowerShellscripting techniques
Dec 5, 2014
Post comments count0
Post likes count0

PowerTip: Create Self-Updating Variable

Doctor Scripto

Summary: Learn how to create a self-updating variable.  How can I create a variable that will automatically update when I call it?  Use Set-PSBreakPoint to set a variable that will always have the current date and time (or only time): Set-PSBreakpoint -Variable Time -Mode Read -Action {$Global:Time=(Get-Date).ToShortTimeString()...

Scripting Guy!Windows PowerShellPowerTip
Dec 5, 2014
Post comments count0
Post likes count0

Use the PowerShell Debugger

Doctor Scripto

Summary: Boe Prox shows how to debug scripts in Windows PowerShell. Honorary Scripting Guy and Windows PowerShell MVP, Boe Prox, here today filling in for my good friend, The Scripting Guy. This is the final part in a series of five posts about troubleshooting Windows PowerShell scripts and functions. The series includes: Over the course ...

Scripting Guy!Windows PowerShellBoe Prox
Dec 4, 2014
Post comments count0
Post likes count0

PowerTip: Use PowerShell to View Trace Sources

Doctor Scripto

Summary: Use Windows PowerShell to view all trace sources.  How can I use Windows PowerShell to see all available trace sources?  Use Get-TraceSource cmdlet: Get-TraceSource | Select Name, Description PS C:> get-tracesource | Select Name, Description  Name            &nbs...

Scripting Guy!Windows PowerShellPowerTip