![]() ' The example creates a file named "WriteFile. String lines = įile.AppendAllLines(Path.Combine(docPath, Convert.ToString("WriteFile.txt")), lines) Create a string array with the lines of text Because the StreamWriter object is declared and instantiated in a using statement, the Dispose method is invoked, which automatically flushes and closes the stream. atendofstream 'read the line from input file linenr linenr 1 strtext objtextfile.readline if ( filenr 1 and linenr <> 2) or ( linenr > 2) then ' write the line to the output file objoutputfile.writeline strtext end if loop objtextfile.close 'move file to backup folder destinationfile backupfolder
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |