home *** CD-ROM | disk | FTP | other *** search
/ Merciful 3 / Merciful_Release_3.bin / software / m / midiplayv2.58.lha / MidiPlay / ARexx / Example2.rexx < prev    next >
OS/2 REXX Batch file  |  1994-08-03  |  642b  |  24 lines

  1. /* This is an example ARexx script for use with MidiPlay.
  2.    Use the following parameter: FILENAMEREXX=ThisScript.rexx
  3.    When MidiPlay has loaded a new file, it calls ThisScript.
  4.    Argument consists of drive, path, file and extension of the filename.
  5.  
  6.    This particular example tries to view a text file with a name
  7.    '.../file.txt' when loaded file was '.../file.mid'. 
  8. */
  9.  
  10. options results
  11.  
  12. parse arg Drive ',' Path ',' File ',' Extension .
  13.  
  14. if Path == "" then Path2 = Path
  15. else Path2 = Path || '/'
  16.  
  17. Ext2 = "txt"
  18. Whole =  '' || Drive || Path2 || File || '.' || Ext2 || ''
  19.  
  20. address command
  21.  
  22. if exists(Whole) then
  23.   'run more' '"'Whole'"'
  24.