While working on one of the small freelance project there was a requirement to find whether launched application/process is minimized or Maximized (For example when I open Microsoft excel what is the state whether it is minimized or maximized). This value of window state you can easily get with UIAutomationClinet .net class object. You can more read about the object on https://docs.microsoft.com/en-us/dotnet/api/system.windows.automation.automationelement?view=netcore-3.1. Below is the screenshot, In the result it shows 3 states non, minimized or maximized.
Download script Get-ProcessWindowStatus.ps1 here or you can download it from github.com/kunaludapi.
Installing, importing and using any module in powershell
Microsoft PowerShell: Check Windows license activation status
Find next available free drive letter using PowerShell
Copy Files with PowerShell Remoting WINRM Protocol
How to Install and Use Microsoft PowerShell on Linux
Configure PowerShell remoting between Windows and Linux
Get-PSRepository WARNING Unable to find module repositories
Invoke-WebRequest : The underlying connection was closed: An unexpected error occurred on a send
Creating an internal PowerShell module repository
How to sign PowerShell ps1 scripts
This post first appeared on Tales From Real IT System Administrators World And Non-production Environment, please read the originial post: here