Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

List string to file C#

string[] lines = { "First line", "Second line", "Third line" };
System.IO.File.WriteAllLines(@"C:UsersPublicTestFolderWriteLines.txt", lines);
lines = { "Fourth line", "Fith line" };
System.IO.File.AppendAllLines(@"C:UsersPublicTestFolderWriteLines.txt", lines);
 
PREVIOUS NEXT
Tagged: #List #string #file
ADD COMMENT
Topic
Name
8+9 =