home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga MA Magazine 1998 #6
/
amigamamagazinepolishissue1998.iso
/
varia
/
heddley
/
archive
/
hedd_golded_temp.rexx
< prev
next >
Wrap
OS/2 REXX Batch file
|
1977-12-31
|
1KB
|
29 lines
/* .rexx */
OPTIONS RESULTS /* enable return codes */
if (LEFT(ADDRESS(), 6) ~= "GOLDED") then /* not started by GoldEd ? */
address 'GOLDED.1'
'LOCK CURRENT' /* lock GUI, gain access */
OPTIONS FAILAT 6 /* ignore warnings */
SIGNAL ON SYNTAX /* ensure clean exit */
SIGNAL ON FAILURE /* trap Heddley errors */
'UNLOCK' /* VERY important: unlock GUI */
EXIT /* quit this macro */
SYNTAX: /* ARexx error... */
SAY "Sorry, error line" SIGL ":" ERRORTEXT(RC) /* report it... */
UNLOCK /* unlock GUI */
EXIT /* exit */
FAILURE: /* Heddley error... */
ERRV=address().LASTERROR /* get name of error var. */
SAY "Error:" VALUE(ERRV) /* report the error */
ADDRESS GOLDED.1 /* talk to GoldED */
UNLOCK /* unlock GUI */
EXIT /* exit */