top of page

PowerShell Helpful Links

PowerShell Helpful Links
  • Microsoft's PowerShell Documentation: This official resource provides comprehensive guides, cmdlet references, and scripting examples directly from Microsoft. It's the go-to place for understanding PowerShell's core concepts and capabilities.

​

​

  • PowerShell Gallery: Managed by Microsoft, this repository hosts thousands of PowerShell modules and scripts contributed by the community. It's ideal for discovering and downloading modules to extend PowerShell's functionality.

​

  • GitHub PowerShell Repositories: GitHub hosts numerous open-source PowerShell projects and repositories. It's a great source for finding scripts, tools, and community-contributed modules that address specific automation and management tasks.

​

  • PowerShell.org: This community-driven site offers forums, blogs, and resources for PowerShell enthusiasts. It's valuable for engaging with the PowerShell community, finding tutorials, and staying updated on the latest developments.

​

  • Stack Overflow PowerShell Tag: Stack Overflow is renowned for its vast collection of programming Q&A. The PowerShell tag is active with questions, answers, and discussions covering a wide range of topics related to scripting and troubleshooting.

​

These resources collectively provide a wealth of information, tools, and community support for anyone looking to learn, improve skills, or solve problems using PowerShell in various IT and automation scenarios.

Code Snippets

Measure - Quick count of items collected
 

  

        Get-Service | Measure | Select Count | Format-list      

​

​

Also Have Count to Count Items in Array / Object / Returned Value


        (Get-Service).count        



Tee-Object - View output and export to text
 

        Get-Service | Select Name, Status | Tee-Object C:\temp\Service.txt -Append

 

 


Startswith - Quick check of string and newline `n

   $Myteststring="MeasureMe"
        
        If ($Myteststring.StartsWith("M")){write-host "Starts with an M"}
        
        write-host `n        
        


        $Myteststring="MeasureMe"
        
        If ($Myteststring.Endswith("e")){write-host "String ends with an e"}
        
        write-host `n

 

 


Start-Sleep - Short sleep in the script
 

   Start-Sleep -Seconds 10
        
        Write-host "You just wasted 10 second of your life :P"

 

 


Pause the script to require a user to press enter.

 

 

Pause 

​

CTRL+J to activate dropdown Intellisense in ISE

​

bottom of page