Invoke-Expression and have it pause until continuing to next line
i need run invoke-expression "c:\program files (x86)\windows media player\wmplayer.exe" , have wait until song done until proceeding.
how start-process -wait instead?
edit: or this: http://stackoverflow.com/questions/2700589/how-to-get-powershell-to-wait-for-invoke-item-completion
also: http://blogs.technet.com/b/industry_insiders/archive/2007/03/12/executing-a-command-line-utility-from-powershell-and-waiting-for-it-to-finish.aspx
Windows Server > Windows PowerShell
Comments
Post a Comment