suppose the path of my executable is equal to "c:\myapp\thefirst", how can i get the "thefirst" string alone ? I already used ExtractFileName, ExtractFilePath , ExtractFileExt , ExtractFileDir , ExtractFileDrive, getcurrentdir but those extract either the complete path or only the executable's filename.
I only need the deepest directory part of the path.