ghacks Technology News

Assign Drive Letters to Folders

This tip is really great if you have some folders on your computer that you are working very often with. Instead of navigating to the folder on the hard drive you assign a drive letter to that folder and can access it like it was a own partition or hard drive on your computer. It is very easy to assign a drive letter to a folder, do the following:

Click Start, Run and enter cmd. This should open the command line interface of your windows operating system. The command that we need is the “subst” command and we use it the following way.

subst drive folder

Lets say you want to assign the drive letter X to the folder d:\movies on your hard drive. To do that you write the following command:

subst x: d:\movies

That is all. Fairly easy isn’t it ? Now the drive letter x: remains accessible as long as you do not turn off or reboot windows. If you want to make this permanent you will have to do the following.

Create a new file and name it drive.bat. Edit the file and add the line subst x: d:\movies to it and save it.

Right click the Start button, select Open All Users. Open Programs, Startup and right click that location. Select New Shortcut, and select the drive.bat file that you created. Select Next and finish. The command will be executed for all users with every startup of windows.

If you are running for example Windows 95 you could edit the autoexec.bat and add the line there.

Enjoyed the article?: Then sign-up for our free newsletter or RSS feed to kick off your day with the latest technology news and tips, or share the article with your friends and contacts on Facebook or Twitter.

Related Articles:

Permanently Assign Drive Letters to USB Devices
Associate Folders With Virtual Drives
How to assign a specific drive letter to the USB drive
DriveLetterView, Manage Windows Drive Letters
Windows Explorer: Display Drive Letters Before Drive Names



About the Author:Martin Brinkmann is a journalist from Germany who founded Ghacks Technology News Back in 2005. He is passionate about all things tech and knows the Internet and computers like the back of his hand. You can follow Martin on Facebook or Twitter.

Author: , Friday August 18, 2006 -
Tags:, , ,


Responses so far:

  1. Anonymous says:

    very nice :)

  2. Adrian says:

    The command works in Window 7 but cannot get the Batch file to run at start up.

Leave a Reply   Follow Ghacks   Subscribe To Comment Rss

Subscribe without commenting

© 2005-2012 Ghacks.net. All Rights Reserved. Privacy Policy - About Us