0

I am trying to change the default location of the documents folder using powershell or cmd specifically.

What I have tried: I have tried changing both the shell folders and user folders registry path and restarted the computer but nothing happens:

reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v Personal /t REG_EXPAND_SZ /d "C:\users\JatonJustice\desktop\testfolder"

But I still see it in the users folder in documents(even after restarting. The picture below is after restarting the computer.): enter image description here

I tried using the answer from here: Set location of Special Folders with PowerShell

However that didn't seem to do anything either: enter image description here

If anyone has any ideas for this, that would be awesome. If I have to I guess I can use wswshell but that is the last resort.

1 Answers1

1

I found out that reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v Personal /t REG_EXPAND_SZ /d "C:\users\JatonJustice\desktop\testfolder" works but when you are using an azure domain account or an amazon workspace account, the registry location for the user shell folders will be in a different place

you can verify the user location of the shell folder key by navigating to HKEY_CURRENT_USER and double checking which account you are in. There are accounts like .DEFAULT, or S-1-5-18 (SYSTEM ACCOUNT), etc.