Read a file one line at a time,
as opposed to reading the entire file at once.



Related tasks

 Read a file character by character
 Input loop.


$reader = [System.IO.File]::OpenText($mancorfile)
try {
	do {
		$line = $reader.ReadLine()
		if ($line -eq $null) { break }
		DoSomethingWithLine($line)
	} while ($TRUE)
} finally {
	$reader.Close()
}
 