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

Dan Brown danoldboy at gmail.com
Fri May 5 00:37:29 EDT 2017


You can communicate between server and desktop using sockets. Chatrev is a
good example of this http://www.bjoernke.com/index.irev?target=chatrev


On 4 May 2017 7:34 pm, "Malte Brill via use-livecode" <
use-livecode at lists.runrev.com> 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?
>
> I tried a couple of things to no avail:
>
> <?lc
>   set the shellCommand to "CMD"
>   put "<html>"
>   put the time
>   put "<br />"
>   put Quote & "thes.exe" & Quote &&"-ui" into tShell
>   try
>     get shell(tShell)
>     put "Result:" && the result & cr &"It:" && it
>     put "<br />"
>     open process tShell for binary read
>    read from process tShell until EOF
>    put "Result:" && the result & cr &"It:" && it
>    put "<br />"
>   catch theErr
>   put theErr
> end try
> put cr
> put the time
> put "</html>"
> ?>
>
> the helper app: In the stack script:
>
> on startup
>   send "boo" to me in 500 millisecs
>   — to make sure all libs are loaded
> end startup
>
> on boo
>   quit
> end boo
>
> on shutdown
>   write "boo" to stdout
> end shutdown
>
> Thanks for all input I can get…
>
> Malte
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode



More information about the use-livecode mailing list