Quantcast
Channel: PowerShell.org » All Posts
Viewing all articles
Browse latest Browse all 13067

Bypassing 'OK' dialog box

$
0
0

I am writing a Powershell script to run a few process automatically, but the last .exe ends with an ‘OK’ dialog box and will not move on to the next command to restart the box until it is acknowledged. I was hoping that maybe if I tried ‘-WarningAction Continue’ common parameters hoping it would acknowledge it, but it didn’t. I was wondering if anybody knows a way for it to automatically acknowledge itself, just bypass it after it completes, or should i use something other than ‘start-process’ cmdlet?

The end of my script where the dialog box pops up.

start-process program.exe -wait
restart-computer -force


Viewing all articles
Browse latest Browse all 13067

Trending Articles