I tried to use cacls to give "Everyone" group access to certain folder. And I failed. As I understand the reason is i'm trying to use groupname in english while my windows is localized. Attempt to use localized groupname succeded. I can't predict language of target system. How can I grant permissions on folder regardless of Windows localization?
Asked
Active
Viewed 364 times
1
-
What version of Windows? – Harry Johnston Feb 03 '12 at 03:17
-
i want to use cacls in bat-file on wide range of systems. From **Win2K** to **Win7**. That's why i can't ise **icacls**. – Aleksandr Kravets Feb 03 '12 at 08:59
-
Is it OK to replace the existing permissions on the folder? – Harry Johnston Feb 04 '12 at 04:40
-
@HarryJohnston: Yes, I think. – Aleksandr Kravets Feb 04 '12 at 15:25
-
The /s option to cacls will do what you want, but I'm not sure which version of the OS introduced it. If cacls /s didn't exist in Windows 2000, then I think you're stuck - you'll probably have to ship an executable along with the batch file. – Harry Johnston Feb 04 '12 at 21:44
-
tried to run icacls from win7 on winxp. no luck. says not proper win32 executable. so can't ship executable – Aleksandr Kravets Feb 06 '12 at 11:36
-
I meant an executable you'd written yourself, or gotten someone to write for you. It would be about ten lines of code. – Harry Johnston Feb 06 '12 at 18:45
1 Answers
0
Best i could do is use version number checking, if winVersion >= 6 then use icacls else use xcacls.vbs which i ship with my script. Though xcacls is extremly slow, it works for me for now. In future - we'll see.

Aleksandr Kravets
- 113
- 7