home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 216.lha / RexxArpLib_v2.1 / rexx / filelist / movefiles.txed < prev    next >
Encoding:
Text File  |  1996-02-15  |  695 b   |  44 lines

  1. /* copyfiles */
  2. OPTIONS results
  3. OPTIONS failat 5
  4. frompath = getenv("dufromdir")
  5. frompath = 'filelist/stripstar'(frompath)
  6.  
  7. topath = getenv("dutodir")
  8. topath = 'filelist/stripstar'(topath)
  9.  
  10. rowno = 'filelist/findbottom'()
  11.  
  12. Jump 2 0
  13.  
  14. do i = 1 to rowno
  15.    
  16.    STATUS L 
  17.    if result = "RESULT" then leave i  
  18.    parse var result name id .
  19.    name = strip(name)
  20.    id = strip(id)
  21.    
  22.    if id = "Dir" then do
  23.       Down
  24.       iterate
  25.    end
  26.    else do
  27.       movestring = "rename "frompath||name" to "topath||name
  28.       address command  movestring
  29.    end
  30.    DLine
  31.    INSERT "---file moved---------*N"
  32.     
  33.  
  34. end
  35.  
  36. "filelist/refresh to"
  37. call delay 120
  38. "filelist/refresh from"
  39.  
  40. MSG frompath
  41.  
  42. exit      
  43.  
  44.