home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 274.lha / NazCron_v1.0 / NCShow.rexx < prev    next >
OS/2 REXX Batch file  |  1989-08-06  |  894b  |  53 lines

  1. /***********************/
  2. /* NCShow.rexx         */
  3. /* 7/20/89 - Don Nafis */
  4. /***********************/
  5.  
  6.  
  7. /* Remove the comments below to trace this script. */
  8. /*--->trace results<---*/
  9.  
  10. options failat 20
  11. options results
  12.  
  13. address NAZCRON
  14.  
  15. 'LIST_EVENTS'
  16. if (rc ~= 0) then say "LIST_EVENTS error " || rc
  17. else
  18. do
  19.   eventlist = result
  20.   numwords = words(eventlist)
  21.  
  22.   if numwords > 0 then do
  23.  
  24.     say
  25.     say 'NazCron - Active Named Events:'
  26.     say
  27.  
  28.     do j=1 to numwords
  29.       event = word(eventlist,j)
  30.       'SHOW_EVENT '|| event
  31.       if (rc = 0) then
  32.         say '->' || event || ' ' || result
  33.       else
  34.         say '->' || event || ' not found.'
  35.     end
  36.   end
  37.   else
  38.   do
  39.     say
  40.     say 'NazCron has no active named events.'
  41.   end
  42.  
  43.   say
  44.  
  45.   'SHOW_STATUS'
  46.   if (rc ~= 0) then
  47.     say 'NazCron command: SHOW_STATUS failed with return code: '||rc
  48.   else
  49.     say 'Status: '||result
  50.   say
  51.  
  52. end
  53.