Showing archive results for September 2012

Sep 8, 2012
Post comments count0
Post likes count0

PowerTip: Don’t Name a Variable $input

Doctor Scripto

Summary: Advice against using $input for a variable name.  Can I use a variable named $input to hold input from the Read-Host cmdlet?  $input is an automatic variable that is used for script blocks in the middle of a pipeline. As such, it would be a very poor choice.  Call the variable something ...

Scripting Guy!Windows PowerShellPowerTip
Sep 8, 2012
Post comments count0
Post likes count0

Weekend Scripter: Exploring New and Improved PowerShell 3.0 Cmdlets

Doctor Scripto

Summary: Microsoft Scripting Guy, Ed Wilson, goes spelunking for new and improved Windows PowerShell 3.0 cmdlets. Microsoft Scripting Guy, Ed Wilson, is here. Today is officially the last day of my vacation. Tomorrow, early in the morning, I hop on a plane and head to Redmond, Washington for a week of meetings. This is not a bad thing because ...

Scripting Guy!Windows PowerShellWeekend Scripter
Sep 7, 2012
Post comments count0
Post likes count0

PowerTip: Use PowerShell to Obtain User Input

Doctor Scripto

Summary: Learn how to use Windows PowerShell to solicit user input.   How can I solicit input from the user?  Use the Read-Host cmdlet: $in = Read-host “enter the data”  

Scripting Guy!Windows PowerShellPowerTip
Sep 7, 2012
Post comments count0
Post likes count0

Discover Windows PowerShell 3.0 Cmdlets

Doctor Scripto

Summary: Microsoft Scripting Guy, Ed Wilson, talks about discovering Windows PowerShell 3.0 cmdlets. Microsoft Scripting Guy, Ed Wilson, is here. There are still a few tickets available for Windows PowerShell Saturday in Charlotte, North Carolina on September 15, 2012. The agenda includes sessions about Active Directory, SharePoint, Exchange Server...

Scripting Guy!Windows PowerShellpowershell 3.0
Sep 6, 2012
Post comments count0
Post likes count0

PowerTip: Finding Letters in Strings with PowerShell

Doctor Scripto

Summary: Learn four ways to use Windows PowerShell to find letters in strings.  I want to find out if a string contains the letter “m.” The string is stored in the variable $a as shown here: $a=”northern hairy-nosed wombat”  Here are a variety of ways to accomplish this: a.  [string]$a.contains(&ldqu...

Scripting Guy!Windows PowerShellPowerTip