.txt files reading
How to read a particular line in .txt file and write it? Console program
8 Replies
you can read all lines then change that line and then rewrite it
File.ReadAllLines
File.WriteAllLines
check on msdn
I dont want to change that line
I only want to write in consol one parrticular line
File.ReadAllLines
File.ReadAllLines Method (System.IO)
Opens a text file, reads all lines of the file into a string array, and then closes the file.
or streamreader up until that line
i think second one is better if there r a million lines
and u want 50th line
em okay
em
how can I rewrite this:
to stop doing when It is in right line?
like u know I want 50th line and it stops and 50th line and it output 50th line
okay
i managed
and I did it
tbh thanks for not answering