Launching Programs Maximized

Start-Process has a parameter called -WindowStyle. With it, you can control the window size of the application you launch. You should use this line to launch notepad maximized:

Start-Process notepad -WindowStyle Maximized

Supported arguments are Maximized, Minimized, Normal, and Hidden. Be sure to watch out with Hidden! You should only use it for programs that do not require user interaction.

Twitter This Tip! ReTweet this Tip!


Posted Feb 26 2010, 08:00 AM by ps1
Concentrated Tech NSoftware Dell Compellent Sponsored by Idera and Concentrated Tech and NSoftware and Dell Compellent
Copyright 2011 PowerShell.com. All rights reserved.