This site uses cookies for analytics, personalized content. By continuing to browse this site, you agree to this use. Learn More

Skip to main content
Microsoft
PowerShell Community
PowerShell Community
  • Home
  • DevBlogs
    • Visual Studio
    • Visual Studio Code
    • Visual Studio for Mac
    • DevOps
    • Developer support
    • CSE Developer
    • Azure SDK
    • IoT
    • Command Line
    • Perf and Diagnostics
    • Dr. International
    • Notification Hubs
    • Math in Office
    • DirectX
    • PIX
    • SurfaceDuo
    • Startups
    • Sustainable Engineering
    • C++
    • Java
    • Java Blog in Chinese
    • JavaScript
    • PowerShell Community
    • PowerShell Team
    • Python
    • Q#
    • TypeScript
    • Visual Basic
    • Visual C#
    • Visual F#
    • .NET
    • ASP.NET
    • NuGet
    • Xamarin
    • #ifdef Windows
    • Apps for Windows
    • Azure Depth Platform
    • Azure Government
    • Bing Dev Center
    • Microsoft Edge Dev
    • Microsoft Azure
    • Office 365 Development
    • Old New Thing
    • Windows MIDI and Music dev
    • Windows Search Platform
    • Azure Cosmos DB
    • Azure Data Studio
    • Azure SQL
    • OData
    • Revolutions R
    • SQL Server Data Tools

    PowerShell Community

    A place for the community to learn PowerShell and share insights

    Category: PowerShell from PowerShell Community

    Testing the connection to computers in the Active Directory
    Testing the connection to computers in the Active Directory
    Avatar @DoctorDNS April 2, 2021 Apr 2, 2021 04/2/21
    Q: As an administrator, I often have to do a lot of reporting on the servers in my domain. Is there a simple way to test the connection to every server in my domain or every server or client host in a specific OU? A: Of course you can do this with PowerShell! You can use the Active Directory cmdlets and Test-Connection, although it is not as ...

    0PowerShell
    Can I Enable the Caps Lock Key?
    Can I Enable the Caps Lock Key?
    Avatar @DoctorDNS March 24, 2021 Mar 24, 2021 03/24/21
    Q: I have a script where users enter some information. This information needs to be entered in all capital letters, so my instructions say, “Please make sure the Caps Lock key is on before entering the information.” They don’t always do that, however. Is there a way to turn the Caps Lock key on and off using a script? A: I don't know ...

    2PowerShell
    A Reusable File System Event Watcher for PowerShell
    A Reusable File System Event Watcher for PowerShell
    Avatar Wolfgang Groß March 18, 2021 Mar 18, 2021 03/18/21
    FSWatcherEngineEvent module provides events of file system changes as powershell engine event

    2PowerShell
    Determine if a folder exists
    Determine if a folder exists
    Avatar Fabian Baumanis March 13, 2021 Mar 13, 2021 03/13/21
    Q: Is there any way to determine whether or not a specific folder exists on a computer? A: There are loads of ways you can do this. The Test-Path Cmdlet The easiest way to do this is to use the Test-Path cmdlet. It looks for a given path and returns True if it exists, otherwise it returns False. You could evaluate the result of the Test-Path...

    2PowerShell
    Reading a text file bottom up
    Reading a text file bottom up
    Avatar @DoctorDNS March 5, 2021 Mar 5, 2021 03/5/21
    Q: I have a log file in which new data is appended to the end of the file. That means the most recent entries are at the end of the file. I’d like to be able to read the file starting with the last line and then ending with the first line, but I can’t figure out how to do that. A: There are loads of ways you can do this. A simple way is ...

    5PowerShell
    Lightning Fast and Easy Provisioning of Git with SSH Key Authentication on Windows
    Lightning Fast and Easy Provisioning of Git with SSH Key Authentication on Windows
    DarwinJS DarwinJS March 1, 2021 Mar 1, 2021 03/1/21
    Maybe you have a team of Windows developers that are onboarding for your new Git server installation or maybe you've decided to drop http password authentication to your existing Git server (due to it's many problems). Your next steps may well be into a rough and rocky rabbit hole when you were holding out hope for simplicity (you know the ...

    3PowerShell
    Leveraging XML with New Employee PowerShell Scripts
    Leveraging XML with New Employee PowerShell Scripts
    Avatar Sam Turner February 27, 2021 Feb 27, 2021 02/27/21
    using XML referencing to bolster up your new employee scripts with information.

    2PowerShell
    Getting Yesterday’s Date
    Getting Yesterday’s Date
    Avatar @DoctorDNS February 26, 2021 Feb 26, 2021 02/26/21
    Q: How can I get yesterday's date? A: You can use a combination of the Get-Date cmdlet and .NET Time/Date methods. First, let's look at dates in PowerShell and .NET Then we can look at how to calculate yesterday and use that in your scripts. Dates in PowerShell Let's start by looking at how you can deal with dates and times. As you ...

    1PowerShell
    Using Get-Service in PowerShell 7 vs. Windows PowerShell 5.1
    Using Get-Service in PowerShell 7 vs. Windows PowerShell 5.1
    Faris Malaeb Faris Malaeb February 23, 2021 Feb 23, 2021 02/23/21
    Q: How can I get the Username, and StartType for a Windows Service? A: Quick answer is PowerShell 7. Microsoft is doing a great job on PowerShell with each version they release. The simple answer to this question is a command called Get-Service. But there is a big update that makes getting the required information much easier with PowerShell...

    7PowerShell
    Changing Drive Letters and Labels via PowerShell
    Changing Drive Letters and Labels via PowerShell
    Avatar @DoctorDNS February 19, 2021 Feb 19, 2021 02/19/21
    Q: I want to change the drive letter and the drive label for a new USB drive. Is there a way with PowerShell? A: Of course. One way is to use WMI and the CIM cmdlets. PowerShell does not have a cmdlet to change the drive letter or the caption directly. But the good news is that you can use WMI and the CIM cmdlets to change both the drive ...

    8PowerShell
    Topics
    .NETActive DirectoryActiveDirectoryAnnouncementArrayBlog newsCaps LockDevOpsFileFileSystemWatcherGitModulenetworkingPowerShellScripting Guys UpdatestringTest-PathToUpper()XML
    Top Bloggers
    Avatar

    @DoctorDNS
    PowerShell Evangelist

    Avatar

    Wolfgang Groß
    Software-Developer

    Doctor Scripto

    Doctor Scripto
    Scripter

    Avatar

    Fabian Baumanis

    DarwinJS

    DarwinJS
    Senior Solutions Architect

    Links
    • About this blog
    • How to contribute to the blog
    • PowerShell Team blog
    • Scripting blog (retired)

    Stay informed

    Login
    Code Block
    What's new
    • Surface Duo
    • Surface Laptop Go
    • Surface Pro X
    • Surface Go 2
    • Surface Book 3
    • Microsoft 365
    • Windows 10 apps
    • HoloLens 2
    Microsoft Store
    • Account profile
    • Download Center
    • Microsoft Store support
    • Returns
    • Order tracking
    • Virtual workshops and training
    • Microsoft Store Promise
    • Financing
    Education
    • Microsoft in education
    • Office for students
    • Office 365 for schools
    • Deals for students & parents
    • Microsoft Azure in education
    Enterprise
    • Azure
    • AppSource
    • Automotive
    • Government
    • Healthcare
    • Manufacturing
    • Financial services
    • Retail
    Developer
    • Microsoft Visual Studio
    • Windows Dev Center
    • Developer Center
    • Microsoft developer program
    • Channel 9
    • Microsoft 365 Dev Center
    • Microsoft 365 Developer Program
    • Microsoft Garage
    Company
    • Careers
    • About Microsoft
    • Company news
    • Privacy at Microsoft
    • Investors
    • Diversity and inclusion
    • Accessibility
    • Security
    English (United States)
    • Sitemap
    • Contact Microsoft
    • Privacy
    • Manage cookies
    • Terms of use
    • Trademarks
    • Safety & eco
    • About our ads
    • © Microsoft 2021