Windows 10: Improper resolution of Documents folder? Solved

  1.    29 Jun 2016 #1

    Improper resolution of Documents folder?


    I have used the Location tab on the Documents folder to move my folder to 'J:\Documents'.

    Click image for larger version. 

Name:	docfolder.png 
Views:	4 
Size:	78.7 KB 
ID:	87414


    In the registry I see these two keys:


    Code:
    [HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders]
    "Personal"="J:\\Documents"
    
    
    [HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders]
    "Personal"=hex(2):4a,00,3a,00,5c,00,44,00,6f,00,63,00,75,00,6d,00,65,00,6e,00,\
      74,00,73,00,00,00
    However, when I use the expression %USERPROFILE%\Documents it always expands incorrectly:


    Code:
    Microsoft Windows [Version 10.0.10586]
    (c) 2015 Microsoft Corporation. All rights reserved.
    
    
    C:\WINDOWS\system32>cd %USERPROFILE%\Documents
    
    
    C:\Users\Jim\Documents>
    What could I be doing wrong?

    I suppose the resolution of %USERPROFILE% is fixed and not context-sensitive, so how should this be expressed for a shell file?
      My ComputerSystem Spec


  2. Posts : 8,864
    Windows 10 Enterprise and Pro/Windows 7 Enterprise/Linux Mint
       29 Jun 2016 #2

    There could be a couple of reasons.

    When you move your Documents folder to another Drive, you are presented with a Popup window that asks if you want to move the contents. If you don't select yes, you can end up with your Documents in both places.

    There is a hidden documents folder which cannot be oved as it is basically a pointer. It holds no documents, it only points to where your documents actually are. Many programs use your documents folder by default. If you move them from the default location, something has to tell them where they are now.

    In the same vein, there are a very few programs which are coded to put their files in C:\Users\Username]Documents. If you have moved them, the program will create a Documents folder in C:\Users.

    If you will go to File Explorer and right click the Documents folder and select properties, it will tell you where your documents actually are. As you can see, mine are on my E drive.

    Click image for larger version. 

Name:	z.png 
Views:	15 
Size:	36.7 KB 
ID:	87416
      My ComputersSystem Spec

  3.    29 Jun 2016 #3

    essenbe said: View Post
    There could be a couple of reasons.

    When you move your Documents folder to another Drive, you are presented with a Popup window that asks if you want to move the contents. If you don't select yes, you can end up with your Documents in both places.
    ...
    Mine are on the J drive.

    Click image for larger version. 

Name:	docs.png 
Views:	5 
Size:	84.3 KB 
ID:	87452

    I did a full move of all the files when I made my user folder (probably on Windows 7). I have updated in-place from 7 to 8 to 8.1 to 10.

    Several of my programs installs made folders on the fixed location 'C:\Users\Jim\Documents'.

    So I do have some stuff there, but most stuff in the proper location.

    However, that does not answer my question about the expansion of the Userprofiles nor how to programs actually locate the correct place.

    This all seems very sloppy to me.

    I guess I am basically asking how does one programmatically find a user 'Documents' folder?

    By the way, 'shell:Personal' resolves properly.
    Last edited by arachnaut; 29 Jun 2016 at 16:54.
      My ComputerSystem Spec

  4.    30 Jun 2016 #4

    I decided to create a junction in C:\Users\Jim called Documents and pointed it to the true location.
    Things seem to be OK now.
      My ComputerSystem Spec


  5. Posts : 3,506
    Win_8.1-Pro, Win_10.1607-Pro, Mint_17.3
       30 Jun 2016 #5

    arachnaut said: View Post
    I decided to create a junction in C:\Users\Jim called Documents and pointed it to the true location.
    Things seem to be OK now.
    Previous versions used to do that for you when you moved the folder(s) through properties > location.

    Windows 10 has implemented a new method of moving the special User folders in Settings > Save locations. This change seems to have affected the properties > location method in that the junction is no longer created.

    essenbe alluded to the junction in his post and you created one manually so the issue is resolved. I don't know if I would characterize this as a bug though - probably.

    I've been on too many versions of Win10 to be absolutely certain the above is factual, but I noticed the same behavior on my machines when I did a Clean install (therefore, no junctions were carried over from an upgrade)

    Good troubleshooting arachnaut.
    Last edited by Slartybart; 30 Jun 2016 at 22:41.
      My ComputerSystem Spec

  6.    30 Jun 2016 #6

    Well, it's also possible that some of my older XP-era programs were problemmatic because they manually created the user folders without checking things properly. So when the folder is in the User area maybe the junction won't be made.

    I moved everything out of the User folders, deleted the User folders, then made the junction to the 'location'.
      My ComputerSystem Spec


 

Related Threads
Two documents folder issue in General Support
My computer came with OneDrive on it. Something I don't actively use, or so I thought. Whenever I save stuff to my computer, I always save it in the documents folder. If I go into the file explorer, it shows documents under This PC, that is where I...
I didn't find an answer to this exact question. Windows 10 Home 1511 x64 clean install. In the left pane of File Explorer there is a Documents folder which points to my OneDrive folder and contains almost nothing (just a few folders that programs...
While web browsing, my PC randomly started acting up. The fan was on full blast and Task Manager showed the 'Windows Modules Installer Worker' was using 30% CPU and using high amounts of memory. It wouldn't stop after 15 minutes, so i decided to...
Solved documents folder in General Support
I try to print out my bank statement but it goes into documents folder. How do I print out from the documents folder when win 10 puts it back?
Solved documents folder in General Support
Paid a bill on line --tried to print---pop-up states it was put into the documents folder. Where is the documents folder located in win 10? P.S---All my questions have been answered quickly by the people in this forum. YOU ARE THE GREATEST,BAR...
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 19:57.
Find Us