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.

FileInfo Methods

July 28, 2014

The FileInfo type exposes the following members.

  NameDescription
Public method AppendText Creates a StreamWriter that appends text to the file represented by this instance of the FileInfo.
Public method CopyTo(String) Copies an existing file to a new file, disallowing the overwriting of an existing file.
Public method CopyTo(String, Boolean) Copies an existing file to a new file, allowing the overwriting of an existing file.
Public method Create Creates a file.
Public method CreateText Creates a StreamWriter that writes a new text file.
Public method Delete Permanently deletes a file. (Overrides FileSystemInfo.Delete().)
Public method Equals(Object) Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.)
Public method GetHashCode Serves as a hash function for a particular type. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method MoveTo Moves a specified file to a new location, providing the option to specify a new file name.
Public method Open(FileMode) Opens a file in the specified mode.
Public method Open(FileMode, FileAccess) Opens a file in the specified mode with read, write, or read/write access.
Public method Open(FileMode, FileAccess, FileShare) Opens a file in the specified mode with read, write, or read/write access and the specified sharing option.
Public method OpenRead Creates a read-only FileStream.
Public method OpenText Creates a StreamReader with UTF8 encoding that reads from an existing text file.
Public method OpenWrite Creates a write-only FileStream.
Public method Refresh Refreshes the state of the object. (Inherited from FileSystemInfo.)
Public method ToString Returns the path as a string. (Overrides Object.ToString().)
Top

Show:
© 2014 Microsoft