Page 1 of 1

Run a shell command: multiple instances of stack

Posted: Tue Jan 21, 2014 6:25 am
by glenn52
I use a button to run a windows script
get shell (commandline) etc
I have tested the command line in Win cmd & *.bat file and it works flawlessly
I run the script (hit button) in the editor and it works flawlessly
As a standalone, I hit button and a second instance of my standalone app runs in front
Win task manager shows the 2 processes running
Close the latest process and the first one does not complete the script

Any ideas please??

Win 7
LC 5.5.5

Re: Run a shell command: multiple instances of stack

Posted: Tue Jan 21, 2014 1:15 pm
by Klaus
Hi Glenn,

not sure what the question is :D

But I guess you want to prevent the second standalone from launching, right?
In that case add a "on relaunch" handler to the stack script:

Code: Select all

on relaunch
  ## do nothing actually :-)
end relaunch
If you do not PASS that message, no other instance of the EXE will be launched!

Best

Klaus

Re: Run a shell command: multiple instances of stack

Posted: Tue Jan 21, 2014 10:23 pm
by glenn52
Thanks Klaus, and yes prevent the 2nd instance from launching
I'll try your solution today
Thanks again

If you/anyone knows why this issue arises in I'd be interested to know...

Re: Run a shell command: multiple instances of stack

Posted: Wed Jan 22, 2014 1:20 am
by glenn52
Klaus, thanks, works
Still interested to know why this issue arises... :?