Re: SETTING FOLDER SECURITY
The code seems to be correct at a first glance (except that I would
use plain GERNERIC_ALL constant instead of cryptic 2032127).
The question: what permissions the folder has after executing
this code (as seen in the Security tab in the folder properties
dialog)?
Russian Software Developer Network - http://www.rsdn.ru
Re: SETTING FOLDER SECURITY
The question to ask is:
Under what user account did you run that piece of code? Does that user account has authorization to grant full access to user "test4".
If the answer is NO, then your code should not and would not work. Because the system is designed to prevent that from happening.
TRUE and FALSE and NOTHING in between. These are the only three building blocks of all computer languages.
Re: SETTING FOLDER SECURITY
From "Administrator" account of course.
But it is not working properly. :(
Re: SETTING FOLDER SECURITY
In the permissions list , in the Security tab, I have set only the "List Folder Contents" right.
The other permissions are cleared.
But there is a strange thing. In the security tab there is one more button: Advanced, used probably for more security options (more refined). And suprize , there , for user "test4" I have "Full control". How the **** could be possible. Here I have full control and in the main security tab window I do not have full control ????
If u have some code todo the **** pls. send it to me. I will be grateful, and pray for U :).
PS: I already tried using the GENERIC_ALL constant, but the result is the same. And not only for this folder, but also for other folders.
Re: SETTING FOLDER SECURITY
I think this is because of unusual inheritance flags.
The new security UI (as compared to NT4-style dialogs) is unable
to show complex security settings on its main page. If it encounters
something that it cannot display, it just cleares all marks and
writes "More security options available but are not viewable here.
Press Advanced button blah, blah, blah...".
I'm not sure you really want only CONTAINER_INHERIT_ACE flag to be set.
Most often both CONTAINER_INHERIT_ACE and OBJECT_INHERIT_ACE flags are
set and this is what Windows security editor expects.
Russian Software Developer Network - http://www.rsdn.ru