System.IO.File.ReadAllText(path) does not read the html file.

Posted by Harikrishna on Stack Overflow See other posts from Stack Overflow or by Harikrishna
Published on 2010-03-15T11:40:32Z Indexed on 2010/03/15 11:59 UTC
Read the original article Hit count: 106

Filed under:
|
|
|

I want to read the html file.And for that I use System.IO.File.ReadAllText(path).It can read all the html file but there is one file which is not read through this function.

I have also used

using (StreamReader reader = File.OpenText(fileName)) { text = reader.ReadToEnd(); But still there is same problem.

What is the reason can be there ? And for that what can be the solution ? Or any other way to read the file ?

© Stack Overflow or respective owner

Related posts about c#

Related posts about .NET