home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga ISO Collection
/
AmigaUtilCD2.iso
/
Programming
/
C
/
SASC6571.LZX
/
extras
/
ttx
/
rexx
/
ttx_sasc
/
GetFilePart
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
NeXTSTEP
RISC OS/Acorn
UTF-8
Wrap
Text File
|
1996-12-24
|
307 b
|
18 lines
/*
** GetFilePart: Extracts the file name from a full file specification.
** So long as that spec is valid, this should not fail.
*/
GetFilePart:
Parse ARG path
dirend = LastPos('/', path)
if dirend = 0 then
dirend = Pos(':',path)
if dirend ~= 0 then
file = SubStr(path,dirend+1)
Return file