- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
public int getFileRowsCount(string pathToFile)
{
System.IO.TextReader streamReader = new System.IO.StreamReader(pathToFile);
int rowsCounter = 0;
while ((streamReader.ReadLine()) != null)
{
rowsCounter++;
}
streamReader.Close();
return rowsCounter;
}