AppendAllLines Method

File.AppendAllLines Method

.NET Framework (current version)
 

Appends lines to a file, and then closes the file.

Namespace:   System.IO
Assembly:  mscorlib (in mscorlib.dll)

NameDescription
System_CAPS_pubmethodSystem_CAPS_staticAppendAllLines(String, IEnumerable<String>)

Appends lines to a file, and then closes the file. If the specified file does not exist, this method creates a file, writes the specified lines to the file, and then closes the file.

System_CAPS_pubmethodSystem_CAPS_staticAppendAllLines(String, IEnumerable<String>, Encoding)

Appends lines to a file by using a specified encoding, and then closes the file. If the specified file does not exist, this method creates a file, writes the specified lines to the file, and then closes the file.

Return to top
Show:
© 2016 Microsoft