Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.

Windows 7: Redirecting Folders Created by Programs During Installation--How To

22 Mar 2012   #1

Windows 7 Business x64
Redirecting Folders Created by Programs During Installation--How To


For years I have benefited from this forum without contributing. I thought it was about time that I return the favor. I don’t have the standing required to post a tutorial, so I’m making my contribution here.

One of my great annoyances is programs that insist on creating folders in My Documents, my user folder, or in the root of my hard drive. If the program doesn’t provide a setting allowing you to change the location, deleting the folder just means the program will recreate it the next time you run the program.

Below, I will walk you through how to redirect a folder that a program creates to a different location with no adverse impact on the functionality of the program. Following these steps, you can permanently relocate all those pesky folders that get created in my documents (MS Fax, Scanning folders, Adobe, etc) to wherever you want them to reside.

The NTFS file system has an inherent feature called symbolic links (also called NTFS junctions). A symbolic link appears to Windows and any programs running in Windows as a real directory but is, in fact, a pointer redirecting the program to another drive or folder. Windows uses symbolic links to maintain backward compatibility. For example, in Windows 7, there is a hidden symbolic link in the root directory entitled “Documents and Settings” that points to the “Users” directory in order to maintain backward compatibility with programs written for XP (turn off “Hide Protected Operating System Files” in Folder Options and see for yourself—after looking, don’t forget to turn it back on!). By creating symbolic links and then hiding the pointer file, you can make ill-behaved programs behave.

Here’s How:
  1. (Optional) For those folders with content you will never need to access, create an out-of the way parent folder in which you will keep all of them. For example, I created a folder entitled “Redirected” in my AppData directory (Note: The AppData folder is hidden. To make it visible, go to Folder Options, View and select to “show hidden files, folders, and drives”)

  2. Go to and download the Junction application (Note: Sysinternals has a plethora of great apps worth checking out). Save the executable somewhere easy to find, like the root of your hard drive (i.e., “c:\”).

  3. Open an elevated command prompt. To do so, in the Windows Search box, type “cmd”. Right click on “cmd.exe” and select to “Run as Administrator”.

  4. At the command prompt, navigate to the directory in which you saved “junction.exe”

    c:\Windows\system32> cd c:\

  5. Leaving the command prompt open, go to Windows Explorer and move the folder you want to redirect to its new location, making note of the full paths of its original and new locations. Note: To see the correct name of the path, click in the open space to the right in the windows path bar at the top of Windows Explorer. Unless you do this, you are not seeing the actual path. For example, the path for “My Documents” will initially display something like this:

    ► [YOUR NAME] ► My Documents ►

    But, when you click in the open space, you will see the actual path:
    c:\Users\[USER FOLDER]\Documents

    It is the actual paths (like immediately above) that you need for the folder that you are redirecting.

  6. Back at the command prompt, type the following commands, substituting the original and new paths for “[ORIGINAL PATH]” and “[NEW PATH]”, but keeping the quotes:

    c:\> junction.exe “[ORIGINAL PATH]” “[NEW PATH]”
    c:\> Attrib +s +h “[ORIGINAL PATH]” /L

    c:\> junction.exe “c:\Users\Steven\Documents\Adobe” “c:\Users\Steven\AppData\Redirected\Adobe” [ALL ON ONE LINE]

    c:\> Attrib +s +h “c:\Users\Steven\Documents\Adobe” /L

    The first command creates the symbolic link to the new location. Note that this command will fail if the folder still exists in its original location, because this command needs to create a link with the exact same name at that same location. Likewise, the command will fail if the folder does not exist at the new location, since the symbolic link is beng configured to point to this location. This is why you must move the folder to its new location before running the command.

    The second command makes the symbolic link a hidden system file so that you won’t see it even if you have selected to “show hidden files, folders, and drives”. The only way to see the link is to uncheck “Hide protected operating system files” in Folder Options—something you shouldn’t ordinarily do.

  7. Repeat steps 5 and 6 for every folder you want to relocate. Your programs will never know you moved them, and you’ll be a lot happier!

My System SpecsSystem Spec


 Redirecting Folders Created by Programs During Installation--How To

Thread Tools

Similar help and support threads for2: Redirecting Folders Created by Programs During Installation--How To
Thread Forum
Make my Programs folders and the "All users" Programs folders match Customization
Wierd alphanumeric folders being created General Discussion
As the only User, why can't I delete some folders I created? General Discussion
New Folders are created as Video folders General Discussion
Are these programs created in Excel Software
Files are also created as folders Music, Pictures & Video
Redirecting Folders in 7 Performance & Maintenance

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd

All times are GMT -5. The time now is 04:56 PM.
Twitter Facebook Google+

Windows 7 Forums

Seven Forums Android App Seven Forums IOS App

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33