automated tests - Kill a separate powershell script from the main script -
i'm using powershell script perform automated testing on web application.
part of script runs small, separate script monitors web app pop ups , closes them if appear. called during main script so:
start-process powershell.exe -argumentlist "-file c:\users\documents\monitor.ps1"
at point though close monitor script, perform commands, , start monitor script again.
is there way me kill monitor script main, without closing main script in process?
you want save variable:
$a = start-process notepad.exe -passthru $a.id 10536
so later kill it.
Comments
Post a Comment