Find out DOS path name (8 character) for the directory

By neokrates, written on March 22, 2011

howto

  • Join date: 11-30-99
  • Posts: 224
View Counter:
  • 4,289 views
Rate it
Ad
Poll
  • Trend: what general purpose computer language will dominate IT industry in the next decade?

    View Results

    Loading ... Loading ...
Feeds:
  • bodytext bodytext bodytext

Given you have dos directory and you need an 8 character format of it. Just switch in the parent directory and use DIR command. Here are some examples

💡 We still sometimes need some path in DOS native 8 chars format. Programs like make or build in commands (cp), would require 255 characters paths for path.

GNU make sometimes fails to work with space in path.

use dir /x in parent directory to find 8 character names of sub-dirs:

c:\parentdir>dir /x

Example:

C:\>dir /x
...
11.01.2008  15:47    <DIR>          DOCUME~1     Documents and Settings
01.12.2006  09:10    <DIR>          MYPROJ~1     My Projects
21.01.2011  14:08    <DIR>          PROGRA~1     Program Files
...

Here, you see that Documents and Settings is DOCUME~1 and Program Files is PROGRA~1

have fun

Be Sociable, Share!
 
Does that help to solve your problem?
VN:F [1.8.5_1061]
Rating: +8 (from 14 votes)
11 votes 'YES'  3 votes 'NO'


TAGS

SOCIAL
Be Sociable, Share!

INCOMING SEARCH TERMS


3 Responses to “Find out DOS path name (8 character) for the directory”

  1. […] Find out DOS path name (8 character) for the directory | thinkplexx.comMar 22, 2011 … Given you have dos directory and you need an 8 character format of it. Just switch in the parent directory and use DIR command. Here are … […]

  2. AutoGeo says:

    Note: This only works in cmd.exe, not in the Powershell console.
    Thanks for the solution.

Leave a Reply