In a script package, you can use the following:
SET Z=&& FOR %%A IN (linkfilename) DO SET Z=%%~aA IF "%Z:~8,1%" == "l" GOTO :IT_A_LINK
it is faster than calling DIR /AL .
%%~aA gets the "linkfilename" attributes,
string 9 char, for example d-------- (directory),
or d-------l directory link,
or --------l link to the file.
%Z:~8,1% then captures only the reprocessing point attribute.
jeffd source share