strong12345 当前离线
少尉
mxxcgzxxx (黑雨)当前离线
中尉
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders] "Desktop"="D:\\我的文档\\桌面"复制代码
TOP
@echo off for /f "tokens=3-5" %%a in ('reg query "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v desktop^|find ":"') do (set "desktop=%%a %%b %%c") echo %desktop% pause复制代码
andyrave 当前离线
二级士官
@echo off & setlocal enableDelayedExpansion For /f "tokens=2*" %%a IN ('reg query "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v Desktop') DO Set "Desktop=%%b" For /f "delims=*" %%i IN ('Call echo %Desktop%') do set Desktop=%%i echo %Desktop% 复制代码