TechRepublic : A ZDNet Tech Community

Mapping drive letters to local folders in Windows XP

Tags: Operating systems, Greg Shultz, Microsoft Windows, Microsoft Windows XP, Windows XP Tips Newsletter

  • Save
  • Print
  • Recommend
  • 19

Takeaway: If you could map a drive letter to a nested folder on your hard disk, then you could access nested subfolders in Windows XP just as easily as you can access shared folders on the network. Learn how to accomplish this task using the Subst command.

If you regularly work with files stored in shared folders on a Windows XP network, chances are that you've used Windows' Map Network Drive command to map a drive letter to that folder. Wouldn't it be nice if you could map a drive letter to a nested folder on your hard disk? Then, you could access nested subfolders just as easily as you can access shared folders on the network.

Fortunately, you can do just that. Unbeknownst to most Windows users, there's an old DOS command called Subst that's designed to associate a drive letter with any local folder—and it's still a viable tool in Windows XP. Here's how to use the Subst command:

  1. Open a Command Prompt window.
  2. Type the following command and press [Enter]:
subst x: C:\{pathname}\foldername}

In the command, x: is any available drive letter and {pathname}\foldername} is the complete path to your selected folder. For example:

Subst K: C:\Downloads\Windows\Drivers

Now, instead of typing the full path, you can reach the Drivers folder by accessing drive K: in Windows Explorer.

Miss a tip?

Check out the Windows XP archive, and catch up on our most recent Windows XP tips.

Stay on top of the latest XP tips and tricks with our free Windows XP newsletter, delivered each Thursday. Automatically sign up today!

  • Save
  • Print
  • Recommend
  • 19

Print/View all Posts Comments on this article

nice tip ... ArthurP | 12/01/05
And in reverse gasman@... | 12/01/05
Create and Invisible Drive Mapping zczc2311@... | 12/01/05
Something I found useful TonytheTiger | 12/02/05
Basically ITCowboy | 12/08/05
Doesn't work for Win98 workstations flabdablet | 12/08/05
From CSCoder: mea culpa innocent_bystander | 12/17/05
Stop it! neilb@... | 12/17/05
Can't get away from DOS! cdplayer | 12/19/05
You Can Map a Network Drive to your own drive using the GUI garry@... | 12/01/05
? on original post and on GUI mapping doherty_david@... | 12/01/05
how to remove the drive letter? oxyjen | 12/01/05
Remove drive lketter JustFishin | 12/01/05
remove drive letter techrepublic@... | 12/01/05
Thanks bbogdan@... | 12/01/05
but not from the command prompt of the mapped drive ITSecurityGuy | 12/01/05
Subst history jefferson.harris@... | 12/08/05
that's what I said [eom] ITSecurityGuy | 01/31/06
Not working for me... rjp@... | 12/13/05
Backslash deesy58 | 12/13/05
Thanks! rjp@... | 12/14/05
Removal of drive letter bbogdan@... | 12/01/05
Right click & select Disconnect garry@... | 12/01/05
Mapping a Network Drive locally poorbass | 12/01/05
null e.laurente@... | 12/01/05
Mapping drives how to poorbass | 12/01/05
SUBST works without LAN and SHARE. dutch_gemini@... | 12/09/05
In Windows XP, yes Chug | 12/12/05
If your computer is shared Tink! | 12/15/05
I can't believe I'm the only old DOS hound neilb@... | 12/01/05
Yawn pcockerell | 12/01/05
Thank you. I like to keep it polished neilb@... | 12/01/05
Is not about that kurdon@... | 12/01/05
Old Dog proud of old tricks - good boy!!! innocent_bystander | 12/02/05
And I care about your opinion because? neilb@... | 12/02/05
I'm Rubber and You're Glue innocent_bystander | 12/02/05
Way over the line with your comments mjost@... | 12/03/05
To way over the line innocent_bystander | 12/03/05
to: cscoder apotheon | 12/03/05
To Apotheon innocent_bystander | 12/03/05
cscoder: markup and emphasis apotheon | 12/03/05
cscoder: If you want to puncture you'd better be sharp neilb@... | 12/03/05
To ... you must be sharp innocent_bystander | 12/03/05
cscoder: I wasn't going to comment further neilb@... | 12/04/05
To Wasn't going to reply innocent_bystander | 12/04/05
cscoder: Thanks neilb@... | 12/04/05
Rubber and glue? maecuff | 12/14/05
Hey cscoder maxwell edison | 12/14/05
To MaeCuff Re Rubber and Glue innocent_bystander | 12/16/05
To Dawg innocent_bystander | 12/16/05
Coder maecuff | 12/18/05
Way to go, Neil. You did it again maxwell edison | 12/14/05
Dear Maxwell innocent_bystander | 12/16/05
cscoder - don't wait for an insult maxwell edison | 12/16/05
WTF Neil, where oh where do you find all these anal retentive types??? sleepin'dawg | 12/14/05
Dawg.. maecuff | 12/15/05
Sorry Mae, I meant no offense but then your son has to be.................. sleepin'dawg | 12/15/05
None taken.. maecuff | 12/15/05
Whatever innocent_bystander | 12/16/05
You only get it now??? I guess that's because you're a fuckwit. ROTFLMAO sleepin'dawg | 12/16/05
You're not... flabdablet | 12/01/05
good one KathyAZ | 12/10/05
Everyone knew it beads@... | 12/03/05
ev'ry thing new is old djelliott@... | 12/09/05
You and me both maxwell edison | 12/14/05
They were called "The Illuminati Switches" in my team neilb@... | 12/15/05
ummm maecuff | 12/15/05
He hasn't been here for a couple of weeks neilb@... | 12/15/05
That's no fun maecuff | 12/15/05
Do you mean. . . . maxwell edison | 12/15/05
No Kidding.. maecuff | 12/16/05
Everybody eh? Tink! | 12/15/05
I wasn't referring to DOS as such neilb@... | 12/15/05
To CSCoder Haters: MEA CULPA innocent_bystander | 12/17/05
cscoder: For God's sake, stop digging! neilb@... | 12/17/05
It's my Karma innocent_bystander | 12/17/05
I'm not sure about the pound of flesh.. maecuff | 12/18/05
Being "offended" is ALWAYS. . . . maxwell edison | 12/17/05
The fearsome foursome maxwell edison | 12/17/05
I'd have to practise much, much more neilb@... | 12/18/05
Mae's one-liners. . . maxwell edison | 12/18/05
Neil.. maecuff | 12/18/05
Are you hiring? apotheon | 12/19/05
I'd love to.. maecuff | 12/19/05
Neil as I asked before, what is it you do, that winds these gits up ??? sleepin'dawg | 12/17/05
Neil as I asked before, what is it you do, that winds these gits up ??? sleepin'dawg | 12/17/05
I really don't know how this happened... neilb@... | 12/18/05
Yes but .. mjost@... | 12/01/05
Issue with Flash Drives Efrain Admin | 12/01/05
Change Flash Drive letters jwest349@... | 12/01/05
Setting flash drive letters flabdablet | 12/01/05
Flash drive letter. michael_orton@... | 12/08/05
Pleeeeeeze people! bulk@... | 12/01/05
No drive letters in Vista by default flabdablet | 12/01/05
Bet you win your bet bulk@... | 12/02/05
Safer beads@... | 12/03/05
Duh bribot@... | 12/09/05
Make it Permanent deesy58 | 12/01/05
Thanks! m33.tmn@... | 09/01/07
This helps with Firefox on networks flabdablet | 12/01/05
Forgive my ignorance but ... gary.peace | 12/02/05
forgiven apotheon | 12/02/05
Using Subst and Windows Installer ChrisH62 | 12/07/05
lots of stuff... Chug | 12/12/05
technically apotheon | 12/12/05
Correct Chug | 12/13/05
Easier way that's more secure jefferson.harris@... | 12/08/05
Laptop access w/o network connection? supmktg@... | 12/08/05
Have u tried Subst? Tink! | 12/15/05
Loopback connector vijim | 02/15/06
Slow Access Mapping Local Folder jcuyno@... | 10/23/06
Help - Invalid Parameter Drive A: nmknight | 12/08/05
My XP Pro works as "SUBST A: E:\" .... mjost@... | 12/08/05
Is the Flash drive plugged in? flabdablet | 12/08/05
Disable the floppy first flabdablet | 12/08/05
Still problem with DOS program nmknight | 12/09/05
Or? Andrew T. Fry | 12/09/05
. . . or not. apotheon | 12/09/05
As Capable?? deesy58 | 12/09/05
What about the reverse??? dave@... | 12/15/05
in Linux and other unices apotheon | 12/16/05
What about the reverse??? dave@... | 12/15/05
Why map drives? ctrimbath@... | 12/19/05
RE: Why map drives? thorntoc2 | 12/23/05
How to do this with \\localhost rlgura@... | 01/27/06
RE: Mapping drive letters to local folders in Windows XP jgdolezal@... | 06/17/07
RE: Mapping drive letters to local folders in Windows XP krazymike@... | 06/12/08
RE: Mapping drive letters to local folders in Windows XP Professor-X | 08/27/08

What do you think?

White Papers, Webcasts, and Downloads

Article Categories

Security
Security Solutions, IT Locksmith
Networking and Communications
E-mail Administration NetNote, Cisco Routers and Switches
CIO and IT Management
Project Management, CIO Issues, Strategies that Scale
Desktops, Laptops & OS
Windows 2000 Professional, Microsoft Word, Microsoft Excel, Microsoft Access, Windows XP,
Data Management
Oracle, SQL Server
Servers
Windows NT, Linux NetNote, Windows Server 2003
Career Development
Geek Trivia
Software/Web Development
Web Development Zone, Visual Basic, .NET

SmartPlanet

Click Here