Calling a livecode executable -ui from LC server and get back a result.

Mark Waddingham mark at
Fri May 5 10:30:22 EDT 2017

Hi Malte,

On 2017-05-04 20:34, Malte Brill via use-livecode wrote:
> Hi all,
> has anybody successfully done this? Especially on Windows? I would
> like to launch a livecode built application from a liveCode server
> script and get the output back (on a Server that I control) Is that
> possible? If so, how?

The problem here is a Windows 'limitation' (well design decision 

Windows has two types of executable - console mode and GUI mode. 
is a GUI mode application, which means that it detaches from the console
and does not work in the way you would expect when run from the 

Now, a while I back I added a wee bit of code to the engine to make it
still do something console-y on Windows: on startup it attempts to 
which at least means the engine can access the console handles it was 
with when doing stdout/stderr/stdin type stuff. However, the limitation 
is that the process is still 'detached' from the parent and so does not
necessarily block open process or shell. (This was done IIRC as a 
from Roger Eller - I can't remember the exact reasons, but the code 
seemed to help his specific case, at least).

There's plenty of stuff about this around - Raymend Chen has plenty to
say about it. One notable article being:

Now, one thing he links to from here is:

You could try using editbin.exe to change the subsystem type 
(editbin.exe is
installed with any of the Visual Studio releases, or tools):

   EDITBIN.EXE /SUBSYSTEM:CONSOLE <livecodestandaloneexe>

Then see if this works in the way you want... It might...

Warmest Regards,


Mark Waddingham ~ mark at ~
LiveCode: Everyone can create apps

More information about the Use-livecode mailing list