Hi,
what about using some kind of Tokenizer (e.g.
split). Just split the input by the PathSeperator, which will return a Stringlist containing one entry per directory (and of course the file). So the first entry will be the drive, the second one contains the "main"-directory, the last one will contain the fileName, the entrys beetween the second and last one are subfolders.
Regards Der Unwissende