1. sub tasks
- Posted by George Walters <gwalters at sc.rr.com> Aug 15, 2001
- 421 views
Does EU have any way to launch another program, pass it a value(or 2), wait for it to finish and receive any return value(or 2)? I have been using this (subtask) in Theos for common things like an Inventory or customer lookup. These would be used by may programs but only one copy of the look-up program need be written. For example the inventory search subtask is used by about 35 programs. If I find a bug in it I only have to change it one place. If I included it in an EU program as a function, I would then have to compile(to C) all programs which use it. Not as convinent as a subtask..... does this make sense? How would you approach this in EU? ...george
2. Re: sub tasks
- Posted by Irv Mullins <irvm at ellijay.com> Aug 15, 2001
- 412 views
On Wednesday 15 August 2001 12:13, George Walters wrote: > > Does EU have any way to launch another program, pass it a value(or 2), wait > for it to finish and receive any return value(or 2)? > > I have been using this (subtask) in Theos for common things like an > Inventory or customer lookup. These would be used by may programs but only > one copy of the look-up program need be written. For example the inventory > search subtask is used by about 35 programs. If I find a bug in it I only > have to change it one place. If I included it in an EU program as a > function, I would then have to compile(to C) all programs which use it. Not > as convinent as a subtask..... does this make sense? How would you approach > this in EU? Why would you have to compile it to C? Any program which "includes" your routine can call it. Regards, Irv
3. Re: sub tasks
- Posted by brian_keene at yahoo.com Aug 15, 2001
- 413 views
George: I would use system() or system_exec() (whichever 1 returns error codes) & pass my input as either stdin or as cmd-line parameters. The returned values would be either via: 1. error codes, 2. stdout, or 3. thru a temp file interface. I think I saw something in the archive that allows a EU prog. to use COM or DDE. That could be another option for passing data back & forth. Regards Brian Keene --- George Walters <gwalters at sc.rr.com> wrote: > > Does EU have any way to launch another program, pass it a value(or > 2), wait > for it to finish and receive any return value(or 2)? > > I have been using this (subtask) in Theos for common things like an > Inventory or customer lookup. These would be used by may programs but > only > one copy of the look-up program need be written. For example the > inventory > search subtask is used by about 35 programs. If I find a bug in it I > only > have to change it one place. If I included it in an EU program as a > function, I would then have to compile(to C) all programs which use > it. Not > as convinent as a subtask..... does this make sense? How would you > approach > this in EU? > > ...george > > > > >
4. Re: sub tasks
- Posted by George Walters <gwalters at sc.rr.com> Aug 15, 2001
- 409 views
Irv, I would at some point like to run all the probrams in a c-compiled state and not always run them in interpretive mode. ...george ----- Original Message ----- From: "Irv Mullins" <irvm at ellijay.com> To: "EUforum" <EUforum at topica.com> Subject: Re: sub tasks > > On Wednesday 15 August 2001 12:13, George Walters wrote: > > > > Does EU have any way to launch another program, pass it a value(or 2), wait > > for it to finish and receive any return value(or 2)? > > > > I have been using this (subtask) in Theos for common things like an > > Inventory or customer lookup. These would be used by may programs but only > > one copy of the look-up program need be written. For example the inventory > > search subtask is used by about 35 programs. If I find a bug in it I only > > have to change it one place. If I included it in an EU program as a > > function, I would then have to compile(to C) all programs which use it. Not > > as convinent as a subtask..... does this make sense? How would you approach > > this in EU? > > Why would you have to compile it to C? > Any program which "includes" your routine can call it. > > Regards, > Irv > > > > >
5. Re: sub tasks
- Posted by Irv Mullins <irvm at ellijay.com> Aug 15, 2001
- 420 views
On Wednesday 15 August 2001 13:49, George Walters wrote: > > Irv, I would at some point like to run all the probrams in a c-compiled > state and not always run them in interpretive mode. Then what you wanted to know was "Can I compile my task into a .dll and call it from Euphoria?" - to which the answer is "yes". Compile the speed critical tasks, and call them from interpreded Eu, or compile everything if you want. Regards, Irv