Popular Posts

Tuesday, 5 July 2011

Read text file in ASP .Net


Suppose you have a notepad file and want to show its contents in your asp.net application, than following coding will be needful to you ;

string Path = "C:/1.txt";
string text = System.IO.File.ReadAllText(Path);
Response.Write(text);

No comments:

Post a Comment