Displaying the contents of Notepad file in asp.net webform dynamically
Hi,
My question is I have a notepad file containing some news related info. Now, when I modify or edit the notepad file the same has to displayed in my .aspx page dynamically for every few seconds
Please provide the code in c#.net
1 Answer
Know the answer? Post it. Somebody with the same question will find it here.

Kirtan PatelRank #292 · 8.6K reputationPosted Jun 10, 2009, 10:31 PM EDT
protected void Page_Load(object sender, EventArgs e) { StreamReader sr = new StreamReader(Server.MapPath("TextFile.txt")); string TextInfile = sr.ReadToEnd(); sr.Close(); Label1.Text = TextInfile; }