How To Convert A Long Filename To A Short Filename
Sometimes it may be desirable to convert a long filename to a short filename, for example when working with the command prompt. A few simple rules can be followed to attain the correct 8.3 filename.
1. A SFN filename can have at most 8 characters before the dot. If it has more than that, you should write the first 6, then put a tilde ~ as the seventh character and a number (usually 1) as the eighth. The number distinguishes it from other files with both the same first six letters and the same extension.
2. Dots are important and must be used even for folder names (if there is a dot in the folder name). If there are multiple dots in the long file/directory name, only the last one is used. The preceding dots should be ignored. If there are more characters than three after the final dot, only the first three are used.
3. Generally:
- Any spaces in the filenames should be ignored when converting to SFN.
- Ignore all dots except the last one. Leave out the other dots, just like the spaces.
- Commas and square brackets are changed to underscores.
- Case is not important, upper case and lower case characters are treated equally.
To find out for sure the SFN or 8.3 names of the files in a directory
use: "dir /x" shows the short names if there is one, and the long names.
or : "dir /-n" shows only the short names, in the original DIR listing format.
Read more about this topic: 8.3 Filename
Famous quotes containing the words convert, long and/or short:
“I have simplified my politics into an utter detestation of all existing governments; and, as it is the shortest and most agreeable and summary feeling imaginable, the first moment of an universal republic would convert me into an advocate for single and uncontradicted despotism. The fact is, riches are power, and poverty is slavery all over the earth, and one sort of establishment is no better, nor worse, for a people than another.”
—George Gordon Noel Byron (17881824)
“Lets start with the three fundamental Rules of Robotics.... We have: one, a robot may not injure a human being, or, through inaction, allow a human being to come to harm. Two, a robot must obey the orders given it by human beings except where such orders would conflict with the First Law. And three, a robot must protect its own existence as long as such protection does not conflict with the First or Second Laws.”
—Isaac Asimov (19201992)
“We approached the Indian Island through the narrow strait called Cook. He said, I xpect we take in some water there, river so high,never see it so high at this season. Very rough water there, but short; swamp steamboat once. Dont paddle till I tell you, then you paddle right along. It was a very short rapid. When we were in the midst of it he shouted paddle, and we shot through without taking in a drop.”
—Henry David Thoreau (18171862)