How to mount a virtual drive letter from a folder

For example of a drive letter, I’ll use D:! For example of a folder, I’ll use C:\D\!

If you don’t have the possibility to create a D: partition, you can easily solve it by mounting any kind of folder as a virtual D: partition!

For example, you could use a folder like C:\D\ as D:!

All you need to do is to create these two .bat files and add them inside C:\D\!

  • mount_d.bat

      @cd %~dp0
      @subst d: .
      @pause
    

    Run this file if you want to mount the current folder as D:

  • unmount_d.bat

      @subst d: /D
      @pause
    

    Run this file if you want to unmount the virtualized D:

Note: if you want to see the virtual mounted D: folder in the admin-runned programs (e.g. PS/3dsMax), run the mount_d.bat as admin as well! (twice: one normal as user, one as admin)

Note2: if you have another component like a CD/DVD burner as D:, you can simply switch it very easily in few seconds! Google it

Screenshots

  • The C:\D\ folder containing the .bat files

    Result Label

  • D: will look like C: in the matter of remaining space

    Result Label

  • The content of D:\ will look like C:\D\

    Result Label

  • How to run the .bats as admin

    Result Label


This site uses Just the Docs, a documentation theme for Jekyll.