D
David I
I am trying to shell a program as so
nResult = shell(" mcrypt.exe", 0)
This works fin but then I want to kill its temp file once it is finished. As
we all know Shell is asynchronous so I have this untill the user closes the
program.
while(tasks.exists(""mcrypt.tmp"))
' Delay
wend
Then the kill
Kill("mcrypt.tmp")
Single stepping through this it appears to work perfectly but in realtime
the kill gives me a 'Path/File access error' intermittently which means my
delay is not working properly. It appears to get to the kill after the
program has been removed from the task list but before it has actually
ended. Is there a better way around this?
And does anybody know what exactly is the task ID returned by the shell
command. It does not appear to have anything to do with the tasks.item
method
Many thanks
nResult = shell(" mcrypt.exe", 0)
This works fin but then I want to kill its temp file once it is finished. As
we all know Shell is asynchronous so I have this untill the user closes the
program.
while(tasks.exists(""mcrypt.tmp"))
' Delay
wend
Then the kill
Kill("mcrypt.tmp")
Single stepping through this it appears to work perfectly but in realtime
the kill gives me a 'Path/File access error' intermittently which means my
delay is not working properly. It appears to get to the kill after the
program has been removed from the task list but before it has actually
ended. Is there a better way around this?
And does anybody know what exactly is the task ID returned by the shell
command. It does not appear to have anything to do with the tasks.item
method
Many thanks