hi Frinny hope u'll notice my new doubt.
how is this downloading option given in asp.net? im using asp.net 1.1 n c# as programming lang and sql server as back end.
i actually tried it worked fine but only for a single file, in case if i give more than i file for download in the same page it gives the first file only for download it isnt considering the second one ....
[code=cpp]
private void Page_Load(objec t sender, System.EventArg s e)
{
Response.Clear( );
string path = Request.QuerySt ring["fname"];
System.IO.FileI nfo a = new System.IO.FileI nfo("c:/IP_Handbook.pdf ");
Response.AddHea der("Content-Disposition","a ttachment;filen ame =" +a.Name);
Response.AddHea der("Content-Length",a.Lengt h.ToString());
Response.Conten tType="applicat ion/octate-stream";
Response.WriteF ile(a.FullName) ;
Response.End();
}[/code]
in the design page i have used 2 hyperlinks and in the url path i hv given the path of the pdf file (which i hv chosen here) - all these design is in webform1 and the code is in another webform2 - where there is nothing in design sheet.
i want to use this technique for archieving monthly newsletter...pl ease help me.
how is this downloading option given in asp.net? im using asp.net 1.1 n c# as programming lang and sql server as back end.
i actually tried it worked fine but only for a single file, in case if i give more than i file for download in the same page it gives the first file only for download it isnt considering the second one ....
[code=cpp]
private void Page_Load(objec t sender, System.EventArg s e)
{
Response.Clear( );
string path = Request.QuerySt ring["fname"];
System.IO.FileI nfo a = new System.IO.FileI nfo("c:/IP_Handbook.pdf ");
Response.AddHea der("Content-Disposition","a ttachment;filen ame =" +a.Name);
Response.AddHea der("Content-Length",a.Lengt h.ToString());
Response.Conten tType="applicat ion/octate-stream";
Response.WriteF ile(a.FullName) ;
Response.End();
}[/code]
in the design page i have used 2 hyperlinks and in the url path i hv given the path of the pdf file (which i hv chosen here) - all these design is in webform1 and the code is in another webform2 - where there is nothing in design sheet.
i want to use this technique for archieving monthly newsletter...pl ease help me.
Comment