21 %MACRO _getAbsPathComponents (i_absPath =
26 %LOCAL l_pathElementCount;
27 %LOCAL l_fileNameStartPos;
30 %LET &o_pathWithoutName=;
32 %IF
"%sysfunc(compress(&i_absPath))" NE
"" %THEN %DO;
33 %IF %sysfunc(index(&i_absPath.,/)) GT 0 %THEN %DO;
34 %LET l_pathElementCount=%sysfunc(countw(&i_absPath.,/));
35 %LET l_fileNameStartPos=%sysfunc(findw(&i_absPath.,%scan(&i_absPath,&l_pathElementCount,/)));
36 %LET &o_pathWithoutName=%sysfunc(substr(&i_absPath.,1,%EVAL(&l_fileNameStartPos. - 2)));
37 %LET &o_fileName = %sysfunc(substr(&i_absPath.,&l_fileNameStartPos.));
40 %LET &o_fileName = &i_absPath;
44 %MEND _getAbsPathComponents;