home *** CD-ROM | disk | FTP | other *** search
/ Amiga MA Magazine 1998 #6 / amigamamagazinepolishissue1998.iso / coders / proasm / rexx / dopus / dopus2ced.dopus < prev    next >
Text File  |  1996-04-29  |  877b  |  35 lines

  1. /* Load DOpus 4 selected files into the CygnusED */
  2. /* 15.06.93 by Daniel Weber                      */
  3.  
  4.  
  5. OPTIONS RESULTS
  6.  
  7. status 3                /* get #of active window     */
  8. win = result
  9. status 13 win                /* get actual selected drive */
  10. path = result
  11. getselectedfiles '+'
  12. IF RC ~= 0 THEN EXIT(0)
  13. files = result
  14.  
  15.  
  16. ADDRESS 'rexx_ced'
  17. DO WHILE files ~=''
  18.   PARSE VAR files txtfile '+' files
  19.   status 16                /* current size of the active file   */
  20.   FileState = result
  21.   status 18                /* #of changes made to the act. file */
  22.   FileState = FileState + result    /* load it only if no file is loaded */
  23.   IF (FileState ~= 0) THEN DO        /* and no changes are made ...       */
  24.     Open New                /* else open a new view  :)          */
  25.     IF (result = 0) THEN DO
  26.       okay1 "Couldn't open a new view!" /* no more views! max. 10 views */
  27.       EXIT(0)
  28.     END
  29.   END
  30.   Open path''txtfile
  31. END
  32.  
  33. EXIT(0)
  34.  
  35.