home *** CD-ROM | disk | FTP | other *** search
/ DTP Toolbox / DTPToolbox.iso / propage4.0 / arexx / splitfilename.rexx < prev    next >
Encoding:
OS/2 REXX Batch file  |  1992-06-17  |  244 b   |  14 lines

  1. /*
  2.     SplitFileName.rexx
  3.     This macro will separate the filename from a pathname
  4. */
  5.  
  6. parse arg pathname
  7.  
  8. colon = lastpos('/', pathname)
  9. if colon = 0 then colon = pos(':', pathname)
  10.  
  11.  
  12. if colon = 0 then return("")
  13. else return(left(pathname, colon))
  14.