Thanks alot for this script Dave. I was dreading having to write a script
of my own, and that probably wouldn't have done anything except crash my
computer!
I set it up in Dopus as a beutifully crafted button in the bottom corner
and pressed it with loving care. But, to my horror the hard disk just
flashed for a few seconds and went out. :((
I ran the script with RX as the command in a KingKon shell and it said to
me:
*10.Workbench:> rx Stuff:Rexx/genesis.rexx *
*+++ Error 46 in line 11: Boolean value not 0 or 1*
*Command returned 10/46: Boolean value not 0 or 1*
*10.Workbench:> *
"Fine" I thought, I'll just have a look at the script and sort it out.
As I looked a line 11, I had a sudden rush of "UH!? What's this?"
Anyone, please help! My Arexx knowledge is fairly basic and as holey as a bit of
swiss cheese! I don't understand!!!
(Here's the script I used in my beutifully crafted DOpus button:)
/*
** ARexx script to go online with Genesis
** Deals with - Finding the GENESIS ARexx port
** - Issuing online command
** - Waiting for Genesis to go online
** - Reporting any errors
** - Being incredibly verbose in most cases ;-)
*/
/* Try to find GENESIS ARexx port: */
p=address()||' '||show('P',,)
if ~pos(' GENESIS',p) then do
say "GENESIS ARexx port not found"
/* You can put a bit in here to load Genesis if you wish, */
/* instead of just exiting. */
exit(0)
end
/* If we get this far, GENESIS has been found */
/* Check to see if Genesis is already Online: */
ADDRESS GENESIS 'isonline'
if RC = 1 then do
say "Genesis is already online."
/* Don't need to issue online command, so exit */
exit(0)
end
else do
say "Issuing online command..."
/* Issue connect command: */
ADDRESS GENESIS 'online'
say "Waiting for connection..."
Do until (_online ~= 0)
/* Wait for Genesis to report that it's not offline anymore: */
ADDRESS GENESIS 'isonline'
_online = RC
end
if _online ~= 1 then do
/* If an error is encountered whilst trying to go online...*/
say "Error "||_online||" from Genesis. [EXITING]."
exit(0)
end
/* Otherwise, 'isonline' reported '1' which means that */
/* Genesis went online successfully */
say "Connection established..."
/* Genesis is now online, so exit */
exit(0)
end
____________________________________________________________
Genesis Mailing List - Info & Archive: http://www.vapor.com/
For Listserver Help: <[EMAIL PROTECTED]>, "HELP"
To Unsubscribe: <[EMAIL PROTECTED]>, "UNSUBSCRIBE"
____________________________________________________________
Genesis Mailing List - Info & Archive: http://www.vapor.com/
For Listserver Help: <[EMAIL PROTECTED]>, "HELP"
To Unsubscribe: <[EMAIL PROTECTED]>, "UNSUBSCRIBE"