I am running test sets from QC with a vb script.
I'd like to know if there is a way to stop the execution of all tests easily ?
When running test manually it's possible to use the "Stop All" button whereas when running test from a script this button is not reachable.
Currently the only way I have found is to reboot the computer which is quite violent [img]/images/graemlins/blush.gif[/img].
Thanks in advance !
There should be a wscript process in task manager that can be killed instead of system reboot or even the QTP process but definietly no need to reboot the machine.
But why would you want to do it?
May be you can add code within the script before each test is opened/executed to check if at all you wanna continue execution and branch out based on that.
-- Here to Learn and share ---
The aim is to be able to stop quickly the execution of a test set if there is a ton of errors in the print window or if all tests are failed since one point.
Since it depends on the context and on who is executing the tests, it cannot be easily solved thanks to code in the script and branch.
I could not exactly understand your problem. Can you elaborate the problem in detail?
Tarun Buy the NEW QTP Descriptive Programming Unplugged Book ** Download QTP Unplugged 2nd Edition eBook for FREE **
you need to figure out the name of the scheduler process.(I dont have it on top of my mind at this time)
Thats easy you can go to the taskmanager and see what process gets added when you run your vbscript.
Whenever you have to stop you can run the command
taskkill /f /im "<<<schedulerprocessname.exe>>& gt;"
1. Run Window or
2. Command prompt or
3. Batch File or
4. VBS file
that will stop the scheduler and further execution of your scripts
in addition you could also kill QTP
taskkill /f /im "qtpro.exe"