0 out of 1 rated this helpful - Rate this topic

File.WriteAllLines Method

Creates a new file, writes one or more strings to the file, and then closes the file.

This member is overloaded. For complete information about this member, including syntax, usage, and examples, click a name in the overload list.

  Name Description
Public method Static member WriteAllLines(String, IEnumerable<String>) Creates a new file, writes a collection of strings to the file, and then closes the file.
Public method Static member WriteAllLines(String, String[]) Creates a new file, write the specified string array to the file, and then closes the file.
Public method Static member WriteAllLines(String, IEnumerable<String>, Encoding) Creates a new file by using the specified encoding, writes a collection of strings to the file, and then closes the file.
Public method Static member WriteAllLines(String, String[], Encoding) Creates a new file, writes the specified string array to the file by using the specified encoding, and then closes the file.
Top
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.