开发者

Windows batch script and privileges for working in HomePath

Funny thing, but I've been working w开发者_StackOverflowith bash, etc but never with Windows' batch scripting.

What I am trying to do is rename some directory in my HomePath. So I simply do:

cd %HOMEPATH%
ren dirName newDirName

And then I get:

Access denied.

Is it even possible in Windows XP / 7 ?

Thanks !


Are you sure that you're already on the correct drive? %HOMEPATH% only gives you the directory, not the drive.

I'd suggest trying:

%HOMEDRIVE%
cd %HOMEPATH%
ren dirName newDirName
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜