using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.IO;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void btnread_Click(object sender, EventArgs e)
{
StreamReader sr = new StreamReader(Request.PhysicalApplicationPath + "nam_email.htm");
while (sr.Peek() >= 0)
{
Response.Write(sr.ReadLine() + "<br />");
}
sr.Close();
}
}Here I will explain how to read text or html file using StreamReader
