M
MuhammadTariq
HI all,
I have a problem while downloading a file from the
server in a dot net web application.
The file downloads successfully,but some html of an
another page is appended at the end of the file.
HERE IS THE CODE FOR DOWNLOADING:
if ( Request.QueryString["qsFileName"]!= null )
{
mFileName = Request.QueryString["qsFileName"];
Page.RegisterStartupScript("CloseMe", "<script> window.close(); </script>");
Response.AppendHeader("content-disposition", "attachment;filename=" +
mFileName);
Response.WriteFile(@Server.MapPath(Request.ApplicationPath +
"/Attachments/") + mFileName);
}
do any body has some idea?????
Thanks in advance.
Regards Tariq.
I have a problem while downloading a file from the
server in a dot net web application.
The file downloads successfully,but some html of an
another page is appended at the end of the file.
HERE IS THE CODE FOR DOWNLOADING:
if ( Request.QueryString["qsFileName"]!= null )
{
mFileName = Request.QueryString["qsFileName"];
Page.RegisterStartupScript("CloseMe", "<script> window.close(); </script>");
Response.AppendHeader("content-disposition", "attachment;filename=" +
mFileName);
Response.WriteFile(@Server.MapPath(Request.ApplicationPath +
"/Attachments/") + mFileName);
}
do any body has some idea?????
Thanks in advance.
Regards Tariq.