Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Directory Methods

The Directory type exposes the following members.

  NameDescription
Public method Static member CreateDirectory Creates all directories and subdirectories as specified by path.
Public method Static member Delete(String) Deletes an empty directory from a specified path.
Public method Static member Delete(String, Boolean) Deletes the specified directory and, if indicated, any subdirectories and files in the directory.
Public method Static member Exists Determines whether the given path refers to an existing directory on disk.
Public method Static member GetCreationTime Gets the creation date and time of a directory.
Public method Static member GetCurrentDirectory Gets the current working directory of the application.
Public method Static member GetDirectories(String) Gets the names of subdirectories (including their paths) in the specified directory.
Public method Static member GetDirectories(String, String) Gets an array of directories (including their paths) that match the specified search pattern in the current directory.
Public method Static member GetDirectoryRoot Returns the volume information, root information, or both for the specified path.
Public method Static member GetFiles(String) Returns the names of files in the specified directory.
Public method Static member GetFiles(String, String) Returns the names of files in the specified directory that match the specified search pattern.
Public method Static member GetFileSystemEntries(String) Returns the names of all files and subdirectories in the specified directory.
Public method Static member GetFileSystemEntries(String, String) Returns an array of file system entries matching the specified search criteria.
Public method Static member GetLastAccessTime Returns the date and time the specified file or directory was last accessed.
Public method Static member GetLastWriteTime Returns the date and time the specified file or directory was last written to.
Public method Static member Move Moves a file or a directory and its contents to a new location.
Public method Static member SetCurrentDirectory Security Critical. Sets the application's current working directory to the specified directory.
Top

Show:
© 2015 Microsoft