If the external program is a simulation it might be necessary to wait for its termination, so that its output can be read afterwards. Add this possibility to execute.
Analysis:
One has to extend the logic of the current functionality to use the ShellExecuteEx() and the WaitForSingleObject() API functions. In addition, one has to ensure that the waiting process can terminate. If the created process won't terminate, one should have the possibility to use the ESC key.
while (true)
{
// wait 1sec and check, whether the user pressed the ESC key
if (WaitForSingleObject(processHandle, 1000) == WAIT_OBJECT_0)
return 0;
if (GetAsynchCancelState())
throw SyntaxError(SyntaxError::PROCESS_CANCELED_BY_USER, ...);
}
Implementation:
The change was implemented as proposed by the analysis [r259]. Implementation tests were passed successfully.
Documentation:
Corresponding changes were made in the language files, the find database the documentation article and the documentation index.
Tests:
The change was tested in production tests. No deviations detected. Change request implemented successfully.
Anonymous
Diff:
Diff:
Diff:
Diff:
Diff:
Related
Commit: [r259]
Diff: