Wednesday, August 5, 2015

PowerShell Tips : Minimize all Desktop Application using PowerShell.

 

In the pervious PowerShell Tip, we have seen that how can create a new empty PowerShell script on the fly.

Ok, today's tip is little bit exciting. Do you what happens when you press Windows Key + D ?

Yes, it, minimise everything. I was trying to achieve the same using PowerShell, and manage to do it. Smile 

Wanna know it? I can tell you, but you have to promise me a coffee ;o) .

It's simple we have to use the New-Object and need to add Shell.Application to a variable and then we need to run the MinimizeAll() method. Simple!

$a = New-Object -ComObject  Shell.Application

$a.MinimizeAll()

 

Aman Dhally - Manya Kaur

Try it now and have fun.

Aman Dhally Manya Kaur

Regards.
Aman Dhally
If you like, you can follow me on Twitter and Facebook. You can also check my “You Tube channel for PowerShell video tutorials. You can download all of my scripts from “Microsoft TechNet Gallery”.

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.