Page 1 of 2

Alternate entry function

Posted: Mon Nov 01, 2010 4:55 pm
by barry.marcus
If I want use <exec> to launch a texis script (i.e., via

<exec BKGND texis myScript></exec>

is there a way to specify an entry point for the call other than the function named main? This would be a convenience more than anything, because I have a number of different calls to make this way and I'd like to keep all of the functions together in a single module if possible.

Alternate entry function

Posted: Mon Nov 01, 2010 5:43 pm
by Kai
Yes, just add it to the script path as you would in a URL:

<exec BKGND texis myScript/someOtherFunc.txt></exec>

Start functions can be given on the command line as they would in URLs.

Alternate entry function

Posted: Mon Nov 01, 2010 5:44 pm
by mark
<exec BKGND texis myScript/something.txt></exec>

http://www.thunderstone.com/site/vortex ... tions.html

Alternate entry function

Posted: Mon Nov 01, 2010 10:50 pm
by barry.marcus
Thanks. Ha! I guess I should RTM more thoroughly! Now, one more question about this...

Here is a simple proof-of-concept test script file, called test, that I wrote:

<script language=Vortex>
<a name=main>
<exec BKGND texis.exe test/longWait.txt>
</exec>
</a>

<a name=longWait PUBLIC>
<vxcp timeout 10000>
<sleep 60>
</a>
</script>

My objective is to demonstrate launching a lengthy process, but having the function that spawns that process return immediately and then end, leaving the lengthy process to continue running.

I am testing this by issuing the following from a command prompt:

texis test

When the <exec> statement in main does NOT include the BKGND option, everything works, except that main waits until the function longWait finishes, as I expect. However, when I add the BKGND option to the <exec> statement (as you see above), I get the following error returned at the command prompt:

000 test:3: Cannot set std[0] flags: The parameter is incorrect in the function TXpopenduplex

What am I doing wrong here?

Alternate entry function

Posted: Tue Nov 02, 2010 10:15 am
by Kai
Your script is correct. That error is something we've encountered before, and haven't yet found a cause for.

Alternate entry function

Posted: Tue Nov 02, 2010 10:33 am
by barry.marcus
Hmm... Do you know of any workaround?

Alternate entry function

Posted: Tue Nov 02, 2010 10:49 am
by Kai
We've been working on one. Contact tech support for a version to test it; it should be available soon.

Alternate entry function

Posted: Mon Nov 08, 2010 1:02 pm
by barry.marcus
Hi. I contacted tech support and they said someone would get back to me re this issue, but as yet no one has. Any progress on a workaround or fix? Thanks.

Alternate entry function

Posted: Mon Nov 08, 2010 1:45 pm
by Kai
A build with a workaround is being built. We'll reply via tech support when it is ready (in a day or two).

Alternate entry function

Posted: Mon Nov 08, 2010 3:46 pm
by barry.marcus
Great! Thanks Kai.