i want to enable scripting, and then run a series of other commands using the system command.
In my code, i am trying to run :
- system("script testfile’);
from within a photon application, and then want to run another set of commands, and all the output of these commands has to be recorded the in testfile.
I have noticed, the moment i run the ‘system("script testfile’);’ the script starts, but is waiting for further inputs from that terminal window.
So even if i do after statement 1):
it is not recognised, as it has not been a input via keyboard.
is there any way round this??
that windows will close if i type ‘exit’, but then that will stop the logging of all text from terminal window.