System.Net.WebClient client = new System.Net.WebClient();
Byte[] buffer = client.DownloadData("D:\\Kannabiran\\dotnet.pdf");
if (buffer != null)
{
Response.Clear();
Response.ContentType = "application/pdf";
Response.AddHeader("content-length", buffer.Length.ToString());
Response.AddHeader("Content-Type", "application/pdf");
Response.BinaryWrite(buffer);
Response.End();
}
Wednesday, February 3, 2010
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment