I have tried to:
Remove a user from the Control Panel, but the C:\Users\bob folder still remains.
Manually deleting it works sometimes if I delete all subfolders, but some users folders do not allow me to delete:
C:\Users\bob\AppData\Roaming\Microsoft\Windows\Libraries
even if a I take ownership...
Deleting the the Account Unknown from System Settings following
instructions from this post , throws the errorProfile not deleted completely. Error - The directory is not empty.
EDIT: I probably should have mentioned that this is in a Windows 10 Home edition.
42 Answers
The steps:
You may notice that the "Libraries" folder disappears from \appdata\roaming\microsoft\windows\Libraries when you do this.
- Delete the User folder!
- Right click
Windows Searchin the services window again and START it.
Following is a copy of the solution How to delete domain user profile from a computer? which should work equally well on a local computer with Windows 10.
- Open up "Control Panel | System and Security | System"
- In the dialog click on "Advanced system settings" (requires Admin rights)
- The "System Properties" dialog will be displayed
- Make sure you are in the "Advanced" register
- In the "User Profiles" section click on "Settings"
- The "User Profiles" dialog is displayed
- Select the account. Hit Delete.
Faster:
- Start | Run
- sysdm.cpl
- switch to register "Advanced"
- In the "User Profiles" section click on "Settings"
- The "User Profiles" dialog is displayed
- Select the account. Hit Delete.
If you have a greyed out button it means that the registry hive has not been released by the operating system, as pointed out by @joeqwerty in the original post.
You could always just delete the C:\Users\[ACCOUNT] directory, but that leaves some registry entries behind that have to be manually deleted.
Deleting any leftover Registry Keys
- Open Regedit with Administrator Permissions (Runas Administrator)
- Select the
HKEY_USERSbranch - Search for the Domain Account without the domain (e.g. login = DOMAIN\ACCOUNT then search for ACCOUNT)
- Keep on searching until the status bar shows
Computer\HKEY_USERS\[SID]\Software\Microsoft\Windwos\CurrentVersion\Explorer\Shell Folders - There should be a large list of your ACCOUNTs folders e.g.
C:\Users\ACCOUNT\Desktop
You are in the right HKEY_USERS\[SID]\Software\Microsoft\Windwos\CurrentVersion\Explorer\Shell Folders branch if the ACCOUNT in "Shell Folders" matches the ACCOUNT you just manually deleted form the C:\Users\[ACCOUNT] directory. This branch [SID] can be exported and/or deleted to clean up the last of the user profile.