Quantcast
Channel: Hey, Scripting Guy! Blog
Viewing all articles
Browse latest Browse all 3333

PowerTip: Cause Out-GridView Cmdlet to Pause

$
0
0

Summary: Use Windows PowerShell to pause the script while the Out-GridView displays.

Hey, Scripting Guy! Question How can I pause the execution of my Windows PowerShell script while the Out-GridView cmdlet displays a grid view?
           (I do not need to pass information from the grid to the script.)

Hey, Scripting Guy! Answer The –Wait parameter from the Out-GridView cmdlet will pause script execution while the grid displays.
           Here is an example:

Get-Process | select name, id | Out-GridView -Wait


Viewing all articles
Browse latest Browse all 3333

Trending Articles