# Why is a subst drive usable from a command prompt but not Windows 7 explorer

I have a registry key under [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run] The value of the key is

"c:\windows\system32\cmd.exe" /c subst t: e:\MyFolder


More often than not when I boot the computer the subst command appears to only half work. If I open a command prompt I can use t: fine. However if I look in windows explorer T: is not there and if I type it into the address bar I get an error message saying "Windows can't find 't:'. Check the spelling and try again."

This is on Windows 7 Enterprise 64 bit.

Any ideas?

-
i've never used subst myself, but this is what Wikipedia has to say on setting up a persistent mapping. hope it helps –  Xantec Dec 2 '10 at 14:03

reg add "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\DOS Devices" /v Z: /t REG_SZ /d "\??\C:\DirectoryName" /f