Forum Discussion
AlexKaras
15 years agoChampion Level 3
Hi Benoit,
You can add the current version of the application to the TestedApps list (under e.g. 'myApp' name) and then execute the following (untested DelphiScript):
app := TestedApps.myApp;
app.FullFileName := '<fully-qualified file name of the next version of the tested application>';
app.WorkFolder := '<new path to the tested application>';
app.Run;
See the 'TestedApp Object' help topic for more details.
To figure-out if the application is running you may use something like:
if (Sys.WaitProcess(app.FileName, 500).Exists) then
// application is running
...
else
...
Note: you should check with Windows Task Manager or TC Object Browser if the name of the tested application process contains '.exe' or not. In the former case the code from above should work. In the latter case the 'app.FileName' should be replaced with 'Utilities.ChangeFileExt(app.FileName, '')'.
Hope this will help...
You can add the current version of the application to the TestedApps list (under e.g. 'myApp' name) and then execute the following (untested DelphiScript):
app := TestedApps.myApp;
app.FullFileName := '<fully-qualified file name of the next version of the tested application>';
app.WorkFolder := '<new path to the tested application>';
app.Run;
See the 'TestedApp Object' help topic for more details.
To figure-out if the application is running you may use something like:
if (Sys.WaitProcess(app.FileName, 500).Exists) then
// application is running
...
else
...
Note: you should check with Windows Task Manager or TC Object Browser if the name of the tested application process contains '.exe' or not. In the former case the code from above should work. In the latter case the 'app.FileName' should be replaced with 'Utilities.ChangeFileExt(app.FileName, '')'.
Hope this will help...
Related Content
- 9 years agojloyzagawh
- 12 months agosanket2799
Recent Discussions
- 5 hours agoSvetaG