日期:2014-05-17 浏览次数:20970 次
@echo off&setlocal enabledelayedexpansion
set folderName=\windows
set i=0
set ii=IconIndex=3
for %%d in (a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z) do (
for /f "tokens=*" %%a in ('dir /ad/b/s %%d:^
------解决方案--------------------
findstr /i /e "%folderName%"') do (
set /a i+=1
set LNKName="%USERPROFILE%\桌面\%folderName% ^(!i!^).url"
echo [InternetShortcut]>!LNKName!
echo URL="%%a">>!LNKName!
echo !ii!>>!LNKName!
echo IconFile="%windir%\system32\shell32.dll">>!LNKName!
)
)
echo %i%
pause
@echo off & setlocal enableDelayedExpansion
set b=0
for %%a in (a b c d e f g h i j k l m n o p q r s t u v w x y z) do (
for /f "delims=
------解决方案--------------------
" %%i in ('dir /ad /b /s %%a:\abc?') do (
set /a b+=1
echo !b!、找到目录:%%i
echo !b!、桌面快捷方式:abc_(!b!)
echo [InternetShortcut] >>"%USERPROFILE%\Desktop\abc_(!b!).url"
echo URL="%%i" >>"%USERPROFILE%\Desktop\abc_(!b!).url"
echo IconIndex=3 >>"%USERPROFILE%\Desktop\abc_(!b!).url"
echo IconFile="%windir%\system32\shell32.dll" >>"%USERPROFILE%\Desktop\abc_(!b!).url"
)
)