- @echo off
- set "file=C:\Users\Administrator\Desktop\智能办公.lnk"
- set "save=D:\Test\SS.txt"
- if not exist "D:\Test" md "D:\Test"
- for /f "delims=" %%i in ('wmic path win32_shortcutfile where "name='%file:\=\\%'" get target /value^|find "="') do set "%%~i"
- if exist %file% (echo %target%>%save%) else echo,>%save%
- pause
复制代码
|