The error “Failed to Enumerate Objects in the Container. Access is denied” usually comes up when you try to change the permissions of a specific file/folder. This usually happens due to incorrect configuration or if there is a clash present.
Many people experience this problem when changing permissions on a file/folder obtained externally or if it is shared by many users. However, there is a quick workaround for this problem. The trick is fully obtaining ownership of the file including all the subfolders.
- Right-click on the file/folder and select “Properties” from the drop-down menu.
- Navigate to the “Security” tab and click on “Advanced” present at the near bottom of the screen. As you can see there are no proper permissions for your account in this case.
- Click on the “Change” button present on the preceding screen. It will be right in front of the owner value. Here we will change the owner of this folder from TrustedInstaller to your computer account. Make sure that you are logged in as administrator.
- Now enter your user account name in the empty space present and click on “Check Names”. Windows will automatically list all the accounts which are a hit with this name.
If you can’t find your account name using this method, you can try selecting it manually from the list of user groups available. Click on “Advanced” and when the new window comes forth, click on “Find Now”. A list will be populated at the bottom of the screen consisting of all the user groups on your computer. Select your account and press “OK”. When you are back to the smaller window, press “OK” again.
- Now check the line “Replace owner on sub containers and objects”. This will ensure that all the folders/files within the folder also change their ownership. This way you won’t have to proceed with all the process again and again for any sub-directories present. You should also check “Replace all child object permission entries with inheritable permission entries from this object”.
- Now close the Properties window after clicking “Apply” and open it again afterward. Navigate to the security tab and click “Advanced”.
- On the permissions window, click on “Add” present at the near bottom of the screen.
- Click on “Select principle”. A similar window will pop up like it did in step 4. Repeat step 4 again when it does. Now check all the permission (giving full control) and press “OK”.
- Check the line “Replace all child object permission entries with inheritable permission entries from this object” and press Apply.
- Close all the folder dialogues and open then again. Check if the error is solved.
What to do if you unable to change Ownership?
Ideally, you would be able to change the ownership of the file/folder using the method described above. If you can’t and a UAC error occurs, we can try another workaround where we disable the UAC settings to “Never Notify”. This way the warning will be suppressed and you will be changing ownership successfully.
- Press Windows + S to launch the Search bar. Type “Change User Account Control Settings” in the dialogue box and open the setting which comes forth.
- Drag the slider all the way down to “Never notify”. Click “OK” to save changes and exit. Make sure that you are logged in as an administrator to perform this action.
- Restart your computer and check if the problem gets solved.
Note: If the problem still persists, you should boot your computer in safe mode and then try taking ownership. If this still doesn’t work, try booting into safe mode with networking.