Files, Directory, IO
Welcome to Files and IO section of C# Corner. In this section, you will find resources related to System.IO namespace and related classes including File, Directory, System.IO, BinaryReader, BinaryWriter, DriveInfo, FileStream, Stream,StreamReader, StreamWriter, TextReader, TextWriter, StringReader, and StringWriter.


  • How To Create Text File in C# and .NET

    File class provides File.Create() method to create a file in C# and .NET. File.CreateText, FileInfo.Create, and FileInfo.CreateText can also be used to create text file in C#. Code sample to create...
  • How To Get File Name In C#

    How to get a file name in C#. The FileInfo.FileName property returns just the file name part of the full path of a file.
  • Delete A directory In C#

    How to delete a directory in C# and .NET. The System.IO.Directory class in the .NET Framework class library provides static methods for creating, copying, moving, and deleting directories and subdi...
  • Amazon Announces Elastic File System for Amazon EC2

    Today, at the AWS Summit, Amazon announced the preview of its new file system, the Amazon Elastic File System.
  • Processing Folders Iteratively

    This article provides a sample of retrieving file system directories iteratively.
  • How to Manage Files which have no Checked in Version

    In this blog we are going to see how to manage files which are not checked in.
  • Password Discovery and Patching by Disassembling

    This article shows how to subvert some of authentication mechanisms, such as extracting vital information imposed in the binary file while source coding, by analyzing the generated hex code itself ...
  • There is not Enough Memory to Complete this Operation when Trying to Close the Project Professional

    There is not enough memory to complete this operation when trying to close the Project Professional.
  • Working With the FileInfo Class in C#

    This article will explain the FileInfo class and its use.
  • File I/O Using C#

    In this article, you will learn how to work with classes in the System.IO namespace for reading data from and writing data to files.
  • Accessing and Maintaining Log Files

    This article defines how to retrieve values from Log files and Event Log View.
  • Copy files from one directory to another

    How to get all file names from a directory/Folder and copy it to another location
  • How to write or create a text file in C#

    The code snippet in this blog demonstrates how to write or create a text file in C#.
  • Remove ReadOnly file attribute

    See this blog code to remove ReadOnly file attribute.
  • File Manager in C#

    File manager is an application that sorts the users file from the system into the proper directory.
  • File Encoding And Decoding In .Net Using Simple IO Operations

    In this blog we will discuss how to encode and decode the files using simple IO operations in .Net.
  • Working with FileInfo and DirectoryInfo classes

    This article explains about the FileInfo and DirectoryClass in the System.IO namespace. The sample application demonstrates how it works.
  • C# File Operations: Part 1

    In this article we will see how we can write something into the file & how we can append our data into an already existing file.
  • C# File Operations: Part 2

    In this article we will see additional file operations like delete a file, copy a file & move a file from source to destination.
  • File creation time in C#

    How to check when a file was created in C#
  • Get File Last Write Time in C#

    In this article we will discuss about how to Get File Last Write Time in C#.
  • Set File Last Write Time in C#

    In this article we will discuss about how to Set File Last Write Time in C#.
  • Decrypt a File in C#

    In this article we will discuss about how to Decrypt a File in C#.
  • Encrypt a File in C#

    In this article we will discuss about how to Encrypt a File in C#.
  • Get File Creation Time in C#

    In this article we will discuss about how to Get File Creation Time in C#.
  • View More
    Files, Directory, IO Experts
    View All