home *** CD-ROM | disk | FTP | other *** search
/ Gold Fish 3 / goldfish_volume_3.bin / files / text / edit / macro / amigae / ec_optec.rexx < prev    next >
OS/2 REXX Batch file  |  1994-11-03  |  920b  |  28 lines

  1. /* $VER: 0.9, ©1994 BURGHARD Eric.                  */
  2. /*           Request E Compiler options             */
  3.  
  4. options results                             /* enable return codes     */
  5.                                             /* not started by GoldEd ? */
  6. if (left(address(), 6) ~= "GOLDED") then address 'GOLDED.1'
  7. 'LOCK CURRENT QUIET'                        /* lock GUI, gain access   */
  8. if rc then exit
  9. options failat 6                            /* ignore warnings         */
  10. signal on syntax                            /* ensure clean exit       */
  11.  
  12. if exists("ENV:ECOpt") then do
  13.   ok=open(readhandle,"ENV:ECOpt","read")
  14.   ecopt=readln(readhandle)
  15.   ok=close(readhandle)
  16. end
  17. else ecopt=""
  18. 'REQUEST TITLE="ECompiler args" BODY="Enter Options" STRING OLD="'ecopt'"'
  19. if rc==0 then address command 'SetEnv ECOpt "'result'"'
  20. 'UNLOCK'
  21. exit
  22.  
  23. syntax:
  24. say "Sorry, error line" SIGL ":" ERRORTEXT(RC) ":-("
  25. 'UNLOCK'
  26. exit
  27.  
  28.