Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Mathematica > Systems Interfaces & Deployment > File Operations > Directories & Directory Operations > DirectoryName >

DirectoryName

DirectoryName
extracts the directory name from the specification for a file.
  • If name contains no directory specification, DirectoryName returns .
  • DirectoryName by default uses pathname separators and other conventions suitable for your operating system.
On Windows get the directory string:
Apply DirectoryName two times:
On Windows get the directory string:
In[1]:=
Click for copyable input
Out[1]=
Apply DirectoryName two times:
In[2]:=
Click for copyable input
Out[2]=
New in 3 | Last modified in 7
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team
Format:   HTML  |  CDF