|
SOLUTIONS
|
BUILT-IN MATHEMATICA SYMBOL
DirectoryName
DirectoryName["name"]
extracts the directory name from the specification for a file.
Details and OptionsDetails and Options
- DirectoryName works differently on different computer systems.
- DirectoryName["directory"] is normally equivalent to ParentDirectory["directory"].
- DirectoryName["name", n] applies DirectoryName n times to name.
- DirectoryName yields output appropriate for use in SetDirectory and ToFileName.
- If name contains no directory specification, DirectoryName["name"] returns
. - DirectoryName by default uses pathname separators and other conventions suitable for your operating system.
- DirectoryName[..., OperatingSystem->"os"] uses the conventions of the specified operating system. Possible choices are
,
, and
.
New in 3 | Last modified in 7
Mathematica 9 is now available!
New to Mathematica?
Find your learning path »
Have a question?
Ask support »
