Jump to content


Photo

Xfat Filename Restrictions


  • Please log in to reply
3 replies to this topic

#1 Kuranes

Kuranes

    X-S Enthusiast

  • Members
  • 16 posts
  • Location:San Francisco, CA
  • Xbox Version:unk

Posted 12 March 2004 - 12:18 AM

Does anyone know exactly what the XFat filename restrictions are? I know the basic idea: 42 characters, some characters not allowed. But exactly which characters aren't allowed? Does the filename have to have a 3 letter .extension? Is there a limit on how long the whole pathname can be? How many nested directories are allowed?

I've looked far and wide and haven't found a definitive source. All the renamers seem to do different things.


#2 P_v

P_v

    X-S Young Member

  • Members
  • Pip
  • 52 posts

Posted 12 March 2004 - 03:57 PM

Software developers have an acronym that I'm sure you've heard before: RTFM. All this information is available in the XDK docs.

File Name Conventions
The FATX file system used for the console hard disk supports file names up to 42 characters long. The UDFX file system used for the DVD player supports file names up to 255 characters long (also known as "long" filenames).

Although each file system can have specific rules about the formation of individual components in a directory or file name, file systems on the Xbox follow some common general conventions.

Both file systems use the backslash (\) character to separate directory names and the file name when forming a path.

General rules for applications creating names for directories and files or processing names supplied by the user include the following:

In general, use only printable characters in a file name. Do not use a path separator, a character in the range 0 through 31, or any character explicitly disallowed by the file system. A specific file system may allow only a certain set of characters in a file name. The FATX file system used for the console hard disk supports the following characters in file names:
! # $ % & ' ( ) - . @ [ ] ^ _ ` { } ~
Numerals 0 through 9
Upper and lower-case letters A through Z
Use the backslash (\) to separate components in a path. No other character is acceptable as a path separator.
UNC names are not supported. UNC names are of the form \\server\share.
Neither the use of a period (.) as a directory component in a path to represent the current directory, nor two consecutive periods (..) to represent the parent of the current directory, are supported.
Use a period (.) to separate the base file name from the extension in a directory name or file name.
Do not use the following characters in directory names or file names, because they are reserved:
< > = ? : ; " * + , / \ |

Do not use characters values 128 through 255.
All paths must be specified as fully-qualified pathnames beginning at the root of a drive and including the drive letter, directories, and file name. For example, "Z:\ai\search.ait". There are no current directory or current drive defaults.
Process a path as a null-terminated string. The maximum length for a FATX full path (directories and file name), including a trailing backslash, is given by MAX_PATH. A UDFX full path can be greater than MAX_PATH, but each component (directory or file name) will be MAX_PATH characters or less.
Do not assume case sensitivity. Consider names such as OSCAR, Oscar, and oscar to be the same.
By following the rules listed in this section, an application can create valid names for files and directories regardless of the file system in use.

Backslashes (\) are used as element dividers in paths (dividing the file name from the path to it, or directories from one another in a path). You cannot use them in file or directory names. They may be required as part of volume names (for example, "T:\").



#3 k8track

k8track

    X-S Young Member

  • Members
  • Pip
  • 35 posts
  • Location:Macomb, IL
  • Interests:My fiancée, disc golf, video games, tennis, hiking, camping, travel, Scandinavian music and culture
  • Xbox Version:v1.6
  • 360 version:none

Posted 09 April 2009 - 04:56 PM

QUOTE(Kuranes @ Mar 11 2004, 06:54 PM) View Post

Does anyone know exactly what the XFat filename restrictions are? I know the basic idea: 42 characters, some characters not allowed. But exactly which characters aren't allowed? Does the filename have to have a 3 letter .extension? Is there a limit on how long the whole pathname can be? How many nested directories are allowed?

I've looked far and wide and haven't found a definitive source. All the renamers seem to do different things.

Bumping a very old thread to ask a quick question for clarification: I've heard 38 characters and I've heard 42. Is it 38 characters + 4 characters for the extension?


#4 cmiz87

cmiz87

    X-S Enthusiast

  • Members
  • 4 posts

Posted 18 July 2009 - 01:13 PM

the xbox has a 42 character file name limit. that includes the extension. the extension can be as long as you want as long as the total file name including the extension is less than or equal to 42 characters.

i hope that helped ! smile.gif




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users